Skip to content

#3327 follow-up: built-ins are calls -- trim _CALLS_OUT_GLOBAL_IGNORE to keywords (contract C2) #3361

Closed

Description

@squid-protocol

Part of #3265, from the #3327 contract audit (docs/calls_out_rule_contract.md, class B). Land after #3328, so the resolver's external class absorbs the new names.

Joe's #3327 decision: built-ins and stdlib are calls. The #3328 resolver labels them external because nothing in the repo defines them. Extraction should not filter them. _CALLS_OUT_GLOBAL_IGNORE (detector.py) mixes true keywords with built-ins:

  • keep (keywords / owned by import): if for while switch catch return sizeof typeof alignof decltype using throw await import require include def function class try except finally require_once include_once
  • remove (built-ins, calls by contract): print println console log echo printf fmt assert expect cast isinstance issubclass hasattr getattr setattr delattr len max min range xrange enumerate zip map filter list dict set tuple bool int float str bytes bytearray memoryview super String Array Object Number Boolean

Per-language _calls_out_ignore sets need the same split. Watch wrapper_extractor.py (#3313 reads calls_out_to: a project wrapper around printf becomes visible) and network_risk_sensor test mapping. Golden bless + rosetta rebless.

Metadata

Metadata

Assignees

No one assigned

    Labels

    core-engineenhancement

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions