Analyzing method of abstract syntax tree and computer program product

An abstract syntax tree and syntax analysis technology, applied in the computer field, can solve the problems of not supporting abstract syntax tree generation, resource consumption, performance degradation, etc., and achieve the effect of improving adaptation efficiency and accuracy

Pending Publication Date: 2022-05-06
ALIBABA CLOUD COMPUTING LTD
View PDF0 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] For example, there are many types of scripting languages ​​for script files, and different types of scripting languages ​​need to use different native compilers; there are syntax incompatibility problems between different versions of the same scripting language; native compilers generate abstract syntax trees and detect The purpose of generating the abstract syntax tree in different ways is not completely consistent. Native compilers often do more checks, including checking whether library symbols exist, etc., and these checks will cause additional resource consumption, which will affect performance degradation; different native compilers The structure of the generated abstract syntax tree often has different meanings, and needs to be customized for different scripting languages; some scripting languages ​​do not support the generation of abstract syntax trees, etc.

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Analyzing method of abstract syntax tree and computer program product
  • Analyzing method of abstract syntax tree and computer program product
  • Analyzing method of abstract syntax tree and computer program product

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0057] Hereinafter, exemplary embodiments of the present disclosure will be described in detail with reference to the accompanying drawings so that those skilled in the art can easily realize them. Also, for clarity, parts not related to describing the exemplary embodiments are omitted in the drawings.

[0058] In the present disclosure, it should be understood that terms such as "comprising" or "having" are intended to indicate the presence of features, numbers, steps, acts, components, parts or combinations thereof disclosed in the specification, and do not exclude one or There is the possibility that multiple other features, numbers, steps, acts, components, parts or combinations thereof exist or are added.

[0059] In addition, it should be noted that, in the case of no conflict, the embodiments in the present disclosure and the features in the embodiments can be combined with each other. The present disclosure will be described in detail below with reference to the accom...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

Embodiments of the invention disclose an abstract syntax tree analysis method and a computer program product. The method comprises the steps of obtaining a script to be analyzed and a compiling type of the script; selecting a target compiling component based on the compiling type; analyzing the script based on the target compiling component, and outputting an abstract syntax tree corresponding to the script; wherein the structure types of the abstract syntax trees output by the target compiling components corresponding to different compiling types are the same. According to the technical scheme, scripts written by various languages can be normalized into abstract syntax trees of the same type, and the adaptation efficiency and accuracy of the scripts can be improved.

Description

technical field [0001] The present disclosure relates to the field of computer technology, in particular to an abstract syntax tree parsing method and a computer program product. Background technique [0002] In the field of script detection, directly performing rule matching on sample files may easily lead to inaccurate matching results, so the sample files are usually converted into an abstract syntax tree, and then rule matching or other detection operations are performed on the basis of the abstract syntax tree. . [0003] However, the inventors of the present disclosure have found that in the prior art, an existing compiler is usually used to convert the scripting language into an abstract syntax tree. Although the accuracy of this method is relatively high, there are also some problems: [0004] For example, there are many types of scripting languages ​​for script files, and different types of scripting languages ​​need to use different native compilers; there are syn...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F8/41
CPCG06F8/41G06F8/42G06F8/427
Inventor 杨健雄
Owner ALIBABA CLOUD COMPUTING LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products