MCPcopy Create free account
hub / github.com/CheckPointSW/Karta / isFileSuitable

Method isFileSuitable

src/core/function_context.py:195–204  ·  view source on GitHub ↗

Check if the given source context can be a possible match, judging only by the files of both contexts. Args: src_ctx (context): source context of the candidate source function Return Value: True iff the src ctx is file-suitable as a match candidate

(self, src_ctx)

Source from the content-addressed store, hash-verified

193 self.selfCheck()
194
195 def isFileSuitable(self, src_ctx):
196 """Check if the given source context can be a possible match, judging only by the files of both contexts.
197
198 Args:
199 src_ctx (context): source context of the candidate source function
200
201 Return Value:
202 True iff the src ctx is file-suitable as a match candidate
203 """
204 return src_ctx.file in self.files or self.isLinkerOptimizationCandidate(src_ctx)
205
206 def isLinkerOptimizationCandidate(self, src_ctx):
207 """Check if the given source context can be a possible match for a linker optimized version of our binary function.

Callers 1

isValidCandidateMethod · 0.80

Calls 1

Tested by

no test coverage detected