-
1.
公开(公告)号:US08677314B1
公开(公告)日:2014-03-18
申请号:US13213036
申请日:2011-08-18
申请人: Craig Silverstein , Zhanyong Wan
发明人: Craig Silverstein , Zhanyong Wan
IPC分类号: G06F9/44
摘要: A system and machine-implemented method modifying a source code file to reduce dependencies included therein. The source code file is parsed to identify a symbol within the source code file, and one or more header files are identified, each of which is capable of resolving the symbol for the source code file. A header file is selected from the one or more header files for inclusion in the source code file, based on a predetermined set of rules. The source code file is modified to include the selected header file.
摘要翻译: 一种修改源代码文件以减少其中包含的依赖性的系统和机器实现的方法。 源代码文件被解析以识别源代码文件中的符号,并且识别一个或多个头文件,每个头文件能够解析源代码文件的符号。 基于预定的一组规则,从一个或多个头文件中选择头文件以包括在源代码文件中。 源代码文件被修改为包括所选的头文件。
-
公开(公告)号:US08881122B1
公开(公告)日:2014-11-04
申请号:US13316432
申请日:2011-12-09
IPC分类号: G06F9/45
摘要: A matching library of a code analysis system defines a number of predicates applicable to an abstract syntax tree (AST) corresponding to program code being analyzed. The predicates represent whether or not nodes of the program code's AST have corresponding properties, such as representing a class that inherits from another given class. The code analysis system obtains an AST to analyze, a predicate expression query that includes predicates of the matching library, and action code. The code analysis system identifies nodes of the AST that match the predicate expression query by executing code of the matching library and executes the action code against the identified nodes.
摘要翻译: 代码分析系统的匹配库定义了适用于与要分析的程序代码相对应的抽象语法树(AST)的多个谓词。 谓词表示程序代码AST的节点是否具有相应的属性,例如表示从另一给定类继承的类。 代码分析系统获得AST来分析,包括匹配库的谓词的谓词表达式查询和操作代码。 代码分析系统通过执行匹配库的代码来识别与谓词表达式查询匹配的AST的节点,并针对所识别的节点执行动作代码。
-