创建您自己的编码规则和编码标准
通过创建用户定义的编码规则和编码标准,检查特定于您的代码库的问题。使用 Polyspace 查询语言 (PQL) 查找您的代码库中的特定问题。通过映射到一个或多个现有的 Polyspace® Bug Finder™ 缺陷和编码规则来检测您的问题。或者,通过创建缺陷检查项来创建新的用户定义的编码规则,这些检查项是 PQL 类谓词的逻辑组合。
将编码规则和编码标准定义为 PQL 代码。使用 polyspace-query-language package 命令将代码翻译为检查项激活文件 (.pschk)。使用 polyspace-query-language test 命令测试 PQL 定义的有效性。
函数
polyspace-query-language | (System Command) Create and test user-defined coding standards and user-defined coding rules (自 R2026a 起) |
类
ObjectWithPosition | Represents an object that has a known position (自 R2026a 起) |
CallSite | Represents a function call site (自 R2026a 起) |
Cast | Represents a cast (自 R2026a 起) |
Field | Represent a field in your code (自 R2026a 起) |
Function | Represents a function in your code (自 R2026a 起) |
Macro | Represents the macros in your code (自 R2026a 起) |
Namespace | Represent namespaces in your code (自 R2026a 起) |
SourceLoc | Query the cast related information in your code (自 R2026a 起) |
Type | Represents the type of a C/C++ object (自 R2026a 起) |
Variable | Represents a variable in your code (自 R2026a 起) |
Lang.String | Represents a string (自 R2026a 起) |
Common | Represents the common types in Polyspace Query Language (自 R2026a 起) |
Node | Represents A node in the abstract syntax tree of your code (自 R2026a 起) |
NumberLiteral | Represents the number_literal nodes in the syntax tree of your code (自 R2026a 起) |
Identifier | Represents the identifier nodes in the syntax tree of your code (自 R2026a 起) |
ExpressionStatement | Represents the expression_statement nodes in the syntax tree of your code (自 R2026a 起) |
Comment | Represents the comment nodes in the syntax tree of your code (自 R2026a 起) |
CallExpression | Represents the call_expression nodes in the syntax tree of your code (自 R2026a 起) |
Declaration | Represents the declaration nodes in the syntax tree of your code (自 R2026a 起) |
AssignmentExpression | Represents the assignment_expression nodes in the syntax tree of your code (自 R2026a 起) |
StringContent | Represents the string_content nodes in the syntax tree of your code (自 R2026a 起) |
IfStatement | Represents the if_statement nodes in the syntax tree of your code (自 R2026a 起) |
ParameterDeclaration | Represents the parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
StringLiteral | Represents the string_literal nodes in the syntax tree of your code (自 R2026a 起) |
BinaryExpression | Represents the binary_expression nodes in the syntax tree of your code (自 R2026a 起) |
TypeQualifier | Represents the type_qualifier nodes in the syntax tree of your code (自 R2026a 起) |
FunctionDefinition | Represents the function_definition nodes in the syntax tree of your code (自 R2026a 起) |
PointerExpression | Represents the pointer_expression nodes in the syntax tree of your code (自 R2026a 起) |
ReturnStatement | Represents the return_statement nodes in the syntax tree of your code (自 R2026a 起) |
TypeDescriptor | Represents the type_descriptor nodes in the syntax tree of your code (自 R2026a 起) |
CaseStatement | Represents the case_statement nodes in the syntax tree of your code (自 R2026a 起) |
EscapeSequence | Represents the escape_sequence nodes in the syntax tree of your code (自 R2026a 起) |
Auto | Represents the auto nodes in the syntax tree of your code (自 R2026a 起) |
CompoundStatement | Represents the compound_statement nodes in the syntax tree of your code (自 R2026a 起) |
FieldExpression | Represents the field_expression nodes in the syntax tree of your code (自 R2026a 起) |
BreakStatement | Represents the break_statement nodes in the syntax tree of your code (自 R2026a 起) |
PreprocInclude | Represents the preproc_include nodes in the syntax tree of your code (自 R2026a 起) |
CastExpression | Represents the cast_expression nodes in the syntax tree of your code (自 R2026a 起) |
StorageClassSpecifier | Represents the storage_class_specifier nodes in the syntax tree of your code (自 R2026a 起) |
True | Represents the true nodes in the syntax tree of your code (自 R2026a 起) |
False | Represents the false nodes in the syntax tree of your code (自 R2026a 起) |
QualifiedIdentifier | Represents the qualified_identifier nodes in the syntax tree of your code (自 R2026a 起) |
PreprocIf | Represents the preproc_if nodes in the syntax tree of your code (自 R2026a 起) |
InitializerList | Represents the initializer_list nodes in the syntax tree of your code (自 R2026a 起) |
Character | Represents the character nodes in the syntax tree of your code (自 R2026a 起) |
ForRangeLoop | Represents the for_range_loop nodes in the syntax tree of your code (自 R2026a 起) |
ForStatement | Represents the for_statement nodes in the syntax tree of your code (自 R2026a 起) |
FieldDeclaration | Represents the field_declaration nodes in the syntax tree of your code (自 R2026a 起) |
TemplateDeclaration | Represents the template_declaration nodes in the syntax tree of your code (自 R2026a 起) |
FieldIdentifier | Represents the field_identifier nodes in the syntax tree of your code (自 R2026a 起) |
PreprocIfdef | Represents the preproc_ifdef nodes in the syntax tree of your code (自 R2026a 起) |
AstNodeProperties | Represents the abstract syntax tree nodes of your code (自 R2026a 起) |
BinaryExpressionOperator | Represents the binary_expression_operator nodes in the syntax tree of your code (自 R2026a 起) |
Character | Represents the character nodes in the syntax tree of your code (自 R2026a 起) |
CompoundRequirement | Represents the compound_requirement nodes in the syntax tree of your code (自 R2026a 起) |
EscapeSequence | Represents the escape_sequence nodes in the syntax tree of your code (自 R2026a 起) |
File | Represents the file nodes in the syntax tree of your code (自 R2026a 起) |
FunctionDefinition | Represents the function_definition nodes in the syntax tree of your code (自 R2026a 起) |
Scope | Represents the scope nodes in the syntax tree of your code (自 R2026a 起) |
SehExceptClause | Represents the seh_except_clause nodes in the syntax tree of your code (自 R2026a 起) |
SehFinallyClause | Represents the seh_finally_clause nodes in the syntax tree of your code (自 R2026a 起) |
StringContent | Represents the string_content nodes in the syntax tree of your code (自 R2026a 起) |
TranslationUnit | Represents the translation_unit nodes in the syntax tree of your code (自 R2026a 起) |
UnaryExpressionOperator | Represents the unary_expression_operator nodes in the syntax tree
of your code (自 R2026a 起) |
AbstractArrayDeclarator | Represents the abstract_array_declarator nodes in the syntax tree
of your code (自 R2026a 起) |
AbstractFunctionDeclarator | Represents the abstract_function_declarator nodes in the syntax
tree of your code (自 R2026a 起) |
AbstractParenthesizedDeclarator | Represents the abstract_parenthesized_declarator nodes in the syntax tree of your code (自 R2026a 起) |
AbstractPointerDeclarator | Represents the asbtract_pointer_declarator nodes in the
syntax tree of your code (自 R2026a 起) |
AbstractReferenceDeclarator | Represents the abstract_reference_declarator nodes in the syntax tree of your code (自 R2026a 起) |
ArrayDeclarator | Represents the array_declarator nodes in the syntax tree of your code (自 R2026a 起) |
AttributedDeclarator | Represents the attributed_declarator nodes in the syntax tree of your code (自 R2026a 起) |
Declarator | Represents the declarator nodes in the syntax tree of your code (自 R2026a 起) |
DestructorName | Represents the destructor_name nodes in the syntax tree of your code (自 R2026a 起) |
FunctionDeclarator | Represents the function_declarator nodes in the syntax tree of your code (自 R2026a 起) |
Identifier | Represents the identifier nodes in the syntax tree of your code (自 R2026a 起) |
OperatorName | Represents the operator_name nodes in the syntax tree of your code (自 R2026a 起) |
ParenthesizedDeclarator | Represents the parenthesized_declarator nodes in the syntax tree of your code (自 R2026a 起) |
PointerDeclarator | Represents the pointer_declarator nodes in the syntax tree of your code (自 R2026a 起) |
QualifiedIdentifier | Represents the qualified_identifier nodes in the syntax tree of your code (自 R2026a 起) |
ReferenceDeclarator | Represents the reference_declarator nodes in the syntax tree of your code (自 R2026a 起) |
StructuredBindingDeclarator | Represents the structured_binding_declarator nodes in the syntax tree of your code (自 R2026a 起) |
TemplateFunction | Represents the template_function nodes in the syntax tree of your code (自 R2026a 起) |
AlignofExpression | Represents the alignof_expression nodes in the syntax tree of your code (自 R2026a 起) |
AssignmentExpression | Represents the assignment_expression nodes in the syntax tree of your code (自 R2026a 起) |
BinaryExpression | Represents the binary_expression nodes in the syntax tree of your code (自 R2026a 起) |
CallExpression | Represents the call_expression nodes in the syntax tree of your code (自 R2026a 起) |
CastExpression | Represents the cast_expression nodes in the syntax tree of your code (自 R2026a 起) |
CharLiteral | Represents the char_literal nodes in the syntax tree of your code (自 R2026a 起) |
CoAwaitExpression | Represents the co_await_expression nodes in the syntax tree of your code (自 R2026a 起) |
CompoundLiteralExpression | Represents the compound_literal_expression nodes in the syntax tree of your code (自 R2026a 起) |
ConcatenatedString | Represents the concatenated_string nodes in the syntax tree of your code (自 R2026a 起) |
ConditionalExpression | Represents the conditional_expression nodes in the syntax tree of your code (自 R2026a 起) |
DeleteExpression | Represents the delete_expression nodes in the syntax tree of your code (自 R2026a 起) |
False | Represents the false nodes in the syntax tree of your code (自 R2026a 起) |
FieldExpression | Represents the field_expression nodes in the syntax tree of your code (自 R2026a 起) |
FoldExpression | Represents the fold_expression nodes in the syntax tree of your
code (自 R2026a 起) |
GenericExpression | Represents the generic_expression nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmExpression | Represents the gnu_asm_expression nodes in the syntax tree of your code (自 R2026a 起) |
LambdaExpression | Represents the lambda_expression nodes in the syntax tree of your code (自 R2026a 起) |
NewExpression | Represents the new_expression nodes in the syntax tree of your code (自 R2026a 起) |
Null | Represents the null nodes in the syntax tree of your code (自 R2026a 起) |
NumberLiteral | Represents the number_literal nodes in the syntax tree of your code (自 R2026a 起) |
OffsetofExpression | Represents the offsetof_expression nodes in the syntax tree of your code (自 R2026a 起) |
ParameterPackExpansion | Represents the parameter_pack_expansion nodes in the syntax tree of your code (自 R2026a 起) |
ParenthesizedExpression | Represents the parenthesized_expression nodes in the syntax tree of your code (自 R2026a 起) |
PointerExpression | Represents the pointer_expression nodes in the syntax tree of your code (自 R2026a 起) |
RawStringLiteral | Represents the raw_string_literal nodes in the syntax tree of your code (自 R2026a 起) |
RequiresClause | Represents the requires_clause nodes in the syntax tree of your code (自 R2026a 起) |
RequiresExpression | Represents the requires_expression nodes in the syntax tree of your code (自 R2026a 起) |
SizeofExpression | Represents the sizeof_expression nodes in the syntax tree of your code (自 R2026a 起) |
StringLiteral | Represents the string_literal nodes in the syntax tree of your code (自 R2026a 起) |
SubscriptExpression | Represents the subscript_expression nodes in the syntax tree of your code (自 R2026a 起) |
This | Represents the this nodes in the syntax tree of your code (自 R2026a 起) |
True | Represents the true nodes in the syntax tree of your code (自 R2026a 起) |
UnaryExpression | Represents the unary_expression nodes in the syntax tree of your code (自 R2026a 起) |
UpdateExpression | Represents the update_expression nodes in the syntax tree of your code (自 R2026a 起) |
UserDefinedLiteral | Represents the user_defined_literal nodes in the syntax tree of your code (自 R2026a 起) |
FieldDeclarator | Represents the field_declarator nodes in the syntax tree of your code (自 R2026a 起) |
FieldIdentifier | Represents the field_identifier nodes in the syntax tree of your code (自 R2026a 起) |
TemplateMethod | Represents the template_method nodes in the syntax tree of your code (自 R2026a 起) |
AccessSpecifier | Represents the access_specifier nodes in the syntax tree of your code (自 R2026a 起) |
AliasDeclaration | Represents the alias_declaration nodes in the syntax tree of your code (自 R2026a 起) |
AlignasQualifier | Represents the alignas_qualifier nodes in the syntax tree of your code (自 R2026a 起) |
ArgumentList | Represents the argument_list nodes in the syntax tree of your code (自 R2026a 起) |
Attribute | Represents the attribute nodes in the syntax tree of your code (自 R2026a 起) |
AttributeDeclaration | Represents the attribute_declaration nodes in the syntax tree of your code (自 R2026a 起) |
AttributeSpecifier | Represents the attribute_specifier nodes in the syntax tree of your code (自 R2026a 起) |
Auto | Represents the auto nodes in the syntax tree of your code (自 R2026a 起) |
BaseClassClause | Represents the base_class_clause nodes in the syntax tree of your code (自 R2026a 起) |
BitfieldClause | Represents the bitfield_clause nodes in the syntax tree of your code (自 R2026a 起) |
CatchClause | Represents the catch_clause nodes in the syntax tree of your code (自 R2026a 起) |
CommaExpression | Represents the comma_expression nodes in the syntax tree of your code (自 R2026a 起) |
Comment | Represents the comment nodes in the syntax tree of your code (自 R2026a 起) |
ConceptDefinition | Represents the concept_definition nodes in the syntax tree of your code (自 R2026a 起) |
ConditionClause | Represents the condition_clause nodes in the syntax tree of your code (自 R2026a 起) |
ConstraintConjunction | Represents the constraint_conjunction nodes in the syntax tree of your code (自 R2026a 起) |
ConstraintDisjunction | Represents the constraint_disjunction nodes in the syntax tree of your code (自 R2026a 起) |
Declaration | Represents the declaration nodes in the syntax tree of your code (自 R2026a 起) |
DeclarationList | Represents the declaration_list nodes in the syntax tree of your code (自 R2026a 起) |
DefaultMethodClause | Represents the default_method_clause nodes in the syntax tree of your code (自 R2026a 起) |
DeleteMethodClause | Represents the delete_method_clause nodes in the syntax tree of your code (自 R2026a 起) |
DependentName | Represents the dependent_name nodes in the syntax tree of your code (自 R2026a 起) |
ElseClause | Represents the else_clause nodes in the syntax tree of your code (自 R2026a 起) |
Enumerator | Represents the enumerator nodes in the syntax tree of your code (自 R2026a 起) |
EnumeratorList | Represents the enumerator_list nodes in the syntax tree of your code (自 R2026a 起) |
ExplicitFunctionSpecifier | Represents the explicit_function_specifier nodes in the syntax tree of your code (自 R2026a 起) |
FieldDeclaration | Represents the field_declaration nodes in the syntax tree of your code (自 R2026a 起) |
FieldDeclarationList | Represents the field_declaration_list nodes in the syntax tree of your code (自 R2026a 起) |
FieldDesignator | Represents the field_designator nodes in the syntax tree of your code (自 R2026a 起) |
FieldInitializer | Represents the field_initializer nodes in the syntax tree of your code (自 R2026a 起) |
FieldInitializerList | Represents the field_initializer_list nodes in the syntax tree of your code (自 R2026a 起) |
FriendDeclaration | Represents the friend_declaration nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmClobberList | Represents the gnu_asm_clobber_list nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmGotoList | Represents the gnu_asm_goto_list nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmInputOperand | Represents the gnu_asm_input_operand nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmInputOperandList | Represents the gnu_asm_input_operand_list nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmOutputOperand | Represents the gnu_asm_output_operand nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmOutputOperandList | Represents the gnu_asm_output_operand_list nodes in the syntax tree of your code (自 R2026a 起) |
GnuAsmQualifier | Represents the gnu_asm_qualifier nodes in the syntax tree of your code (自 R2026a 起) |
InitDeclarator | Represents the init_declarator nodes in the syntax tree of your code (自 R2026a 起) |
InitializerList | Represents the initializer_list nodes in the syntax tree of your code (自 R2026a 起) |
InitializerPair | Represents the initializer_pair nodes in the syntax tree of your code (自 R2026a 起) |
InitStatement | Represents the init_statement nodes in the syntax tree of your code (自 R2026a 起) |
LambdaCaptureSpecifier | Represents the lambda_capture_specifier nodes in the syntax tree of your code (自 R2026a 起) |
LambdaDefaultCapture | Represents the lambda_default_capture nodes in the syntax tree of your code (自 R2026a 起) |
LinkageSpecification | Represents the linkage_specification nodes in the syntax tree of your code (自 R2026a 起) |
LiteralSuffix | Represents the literal_suffix nodes in the syntax tree of your code (自 R2026a 起) |
MsBasedModifier | Represents the ms_based_modifier nodes in the syntax tree of your code (自 R2026a 起) |
MsCallModifier | Represents the ms_call_modifier nodes in the syntax tree of your code (自 R2026a 起) |
MsDeclspecModifier | Represents the ms_declspec_modifier nodes in the syntax tree of your code (自 R2026a 起) |
MsPointerModifier | Represents the ms_pointer_modifier nodes in the syntax tree of your code (自 R2026a 起) |
MsRestrictModifier | Represents the ms_restrict_modifier nodes in the syntax tree of your code (自 R2026a 起) |
MsSignedPtrModifier | Represents the ms_signed_ptr_modifier nodes in the syntax tree of your code (自 R2026a 起) |
MsUnalignedPtrModifier | Represents the ms_unaligned_ptr_modifier nodes in the syntax tree of your code (自 R2026a 起) |
MsUnsignedPtrModifier | Represents the ms_unsigned_ptr_modifier nodes in the syntax tree of your code (自 R2026a 起) |
NamespaceAliasDefinition | Represents the namespace_alias_definition nodes in the syntax tree of your code (自 R2026a 起) |
NamespaceDefinition | Represents the namespace_definition nodes in the syntax tree of your code (自 R2026a 起) |
NamespaceIdentifier | Represents the namespace_identifier nodes in the syntax tree of your code (自 R2026a 起) |
NestedNamespaceSpecifier | Represents the nested_namespace_specifier nodes in the syntax tree of your code (自 R2026a 起) |
NewDeclarator | Represents the new_declarator nodes in the syntax tree of your code (自 R2026a 起) |
Noexcept | Represents the noexcept nodes in the syntax tree of your code (自 R2026a 起) |
OperatorCast | Represents the operator_cast nodes in the syntax tree of your code (自 R2026a 起) |
OptionalParameterDeclaration | Represents the optional_parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
OptionalTypeParameterDeclaration | Represents the optional_type_parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
ParameterDeclaration | Represents the parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
ParameterList | Represents the parameter_list nodes in the syntax tree of your code (自 R2026a 起) |
PointerTypeDeclarator | Represents the pointer_type_declarator nodes in the syntax tree of your code (自 R2026a 起) |
PreprocArg | Represents the preproc_arg nodes in the syntax tree of your code (自 R2026a 起) |
PreprocCall | Represents the preproc_call nodes in the syntax tree of your code (自 R2026a 起) |
PreprocDef | Represents the preproc_def nodes in the syntax tree of your code (自 R2026a 起) |
PreprocDefined | Represents the preproc_defined nodes in the syntax tree of your code (自 R2026a 起) |
PreprocDirective | Represents the preproc_directive nodes in the syntax tree of your code (自 R2026a 起) |
PreprocElif | Represents the preproc_elif nodes in the syntax tree of your code (自 R2026a 起) |
PreprocElifdef | Represents the preproc_elifdef nodes in the syntax tree of your code (自 R2026a 起) |
PreprocElse | Represents the preproc_else nodes in the syntax tree of your code (自 R2026a 起) |
PreprocFunctionDef | Represents the preproc_function_def nodes in the syntax tree of your code (自 R2026a 起) |
PreprocIf | Represents the preproc_if nodes in the syntax tree of your code (自 R2026a 起) |
PreprocIfdef | Represents the preproc_ifdef nodes in the syntax tree of your code (自 R2026a 起) |
PreprocInclude | Represents the preproc_include nodes in the syntax tree of your code (自 R2026a 起) |
PreprocParams | Represents the preproc_params nodes in the syntax tree of your code (自 R2026a 起) |
PureVirtualClause | Represents the pure_virtual_clause nodes in the syntax tree of your code (自 R2026a 起) |
RawStringContent | Represents the raw_string_content nodes in the syntax tree of your code (自 R2026a 起) |
RawStringDelimiter | Represents the raw_string_delimiter nodes in the syntax tree of your code (自 R2026a 起) |
RefQualifier | Represents the ref_qualifier nodes in the syntax tree of your code (自 R2026a 起) |
RequirementSeq | Represents the requirement_seq nodes in the syntax tree of your code (自 R2026a 起) |
SimpleRequirement | Represents the simple_requirement nodes in the syntax tree of your code (自 R2026a 起) |
StatementIdentifier | Represents the statement_identifier nodes in the syntax tree of your code (自 R2026a 起) |
StaticAssertDeclaration | Represents the static_assert_declaration nodes in the syntax tree of your code (自 R2026a 起) |
StorageClassSpecifier | Represents the storage_class_specifier nodes in the syntax tree of your code (自 R2026a 起) |
SubscriptArgumentList | Represents the subscript_argument_list nodes in the syntax tree of your code (自 R2026a 起) |
SubscriptDesignator | Represents the subscript_designator nodes in the syntax tree of your code (自 R2026a 起) |
SubscriptRangeDesignator | Represents the subscript_range_designator nodes in the syntax tree of your code (自 R2026a 起) |
SystemLibString | Represents the system_lib_string nodes in the syntax tree of your code (自 R2026a 起) |
TemplateArgumentList | Represents the template_argument_list nodes in the syntax tree of your code (自 R2026a 起) |
TemplateDeclaration | Represents the template_declaration nodes in the syntax tree of your code (自 R2026a 起) |
TemplateInstantiation | Represents the template_instantiation nodes in the syntax tree of your code (自 R2026a 起) |
TemplateParameterList | Represents the template_parameter_list nodes in the syntax tree of your code (自 R2026a 起) |
TemplateTemplateParameterDeclaration | Represents the template_template_parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
ThrowSpecifier | Represents the throw_specifier nodes in the syntax tree of your code (自 R2026a 起) |
TrailingReturnType | Represents the trailing_return_type nodes in the syntax tree of your code (自 R2026a 起) |
TypeDefinition | Represents the type_definition nodes in the syntax tree of your code (自 R2026a 起) |
TypeDescriptor | Represents the type_descriptor nodes in the syntax tree of your code (自 R2026a 起) |
TypeParameterDeclaration | Represents the type_parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
TypeQualifier | Represents the type_qualifier nodes in the syntax tree of your code (自 R2026a 起) |
TypeRequirement | Represents the type_requirement nodes in the syntax tree of your code (自 R2026a 起) |
UsingDeclaration | Represents the using_declaration nodes in the syntax tree of your code (自 R2026a 起) |
VariadicDeclarator | Represents the variadic_declarator nodes in the syntax tree of your code (自 R2026a 起) |
VariadicParameter | Represents the variadic_parameter nodes in the syntax tree of your code (自 R2026a 起) |
VariadicParameterDeclaration | Represents the variadic_parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
VariadicTypeParameterDeclaration | Represents the variadic_type_parameter_declaration nodes in the syntax tree of your code (自 R2026a 起) |
Virtual | Represents the virtual nodes in the syntax tree of your code (自 R2026a 起) |
VirtualSpecifier | Represents the virtual_specifier nodes in the syntax tree of your code (自 R2026a 起) |
AttributedStatement | Represents the attributed_statement nodes in the syntax tree of your code (自 R2026a 起) |
BreakStatement | Represents the break_statement nodes in the syntax tree of your code (自 R2026a 起) |
CaseStatement | Represents the case_statement nodes in the syntax tree of your code (自 R2026a 起) |
CompoundStatement | Represents the compound_statement nodes in the syntax tree of your code (自 R2026a 起) |
ContinueStatement | Represents the continue_statement nodes in the syntax tree of your code (自 R2026a 起) |
CoReturnStatement | Represents the co_return_statement nodes in the syntax tree of your code (自 R2026a 起) |
CoYieldStatement | Represents the co_yield_statement nodes in the syntax tree of your code (自 R2026a 起) |
DoStatement | Represents the do_statement nodes in the syntax tree of your code (自 R2026a 起) |
ExpressionStatement | Represents the expression_statement nodes in the syntax tree of your code (自 R2026a 起) |
ForRangeLoop | Represents the for_range_loop nodes in the syntax tree of your code (自 R2026a 起) |
ForStatement | Represents the for_statement nodes in the syntax tree of your code (自 R2026a 起) |
GotoStatement | Represents the goto_statement nodes in the syntax tree of your code (自 R2026a 起) |
IfStatement | Represents the if_statement nodes in the syntax tree of your code (自 R2026a 起) |
LabeledStatement | Represents the labeled_statement nodes in the syntax tree of your code (自 R2026a 起) |
ReturnStatement | Represents the return_statement nodes in the syntax tree of your code (自 R2026a 起) |
SehLeaveStatement | Represents the seh_leave_statement nodes in the syntax tree of your code (自 R2026a 起) |
SehTryStatement | Represents the seh_try_statement nodes in the syntax tree of your code (自 R2026a 起) |
Statement | Represents the statement nodes in the syntax tree of your code (自 R2026a 起) |
SwitchStatement | Represents the switch_statement nodes in the syntax tree of your code (自 R2026a 起) |
ThrowStatement | Represents the throw_statement nodes in the syntax tree of your code (自 R2026a 起) |
TryStatement | Represents the try_statement nodes in the syntax tree of your code (自 R2026a 起) |
WhileStatement | Represents the while_statement nodes in the syntax tree of your code (自 R2026a 起) |
PrimitiveType | Represents the primitive_type nodes in the syntax tree of your code (自 R2026a 起) |
TypeIdentifier | Represents the type_identifier nodes in the syntax tree of your code (自 R2026a 起) |
ClassSpecifier | Represents the class_specifier nodes in the syntax tree of your code (自 R2026a 起) |
Decltype | Represents the decltype nodes in the syntax tree of your code (自 R2026a 起) |
DependentType | Represents the dependent_type nodes in the syntax tree of your code (自 R2026a 起) |
EnumSpecifier | Represents the enum_specifier nodes in the syntax tree of your code (自 R2026a 起) |
PlaceholderTypeSpecifier | Represents the placeholder_type_specifier nodes in the syntax tree of your code (自 R2026a 起) |
SizedTypeSpecifier | Represents the sized_type_specifier nodes in the syntax tree of your code (自 R2026a 起) |
StructSpecifier | Represents the struct_specifier nodes in the syntax tree of your code (自 R2026a 起) |
TemplateType | Represents the template_type nodes in the syntax tree of your code (自 R2026a 起) |
UnionSpecifier | Represents the union_specifier nodes in the syntax tree of your code (自 R2026a 起) |
Norm | Contains predicates that check if a keyword is a C or C++ keyword (自 R2026a 起) |
主题
快速入门
- Get Started with Polyspace Query Language
Create a new coding standard and a simple coding rule using Polyspace Query Language.
Polyspace 查询语言语法
- General Polyspace Query Language Syntax
Learn the general PQL syntax. - Polyspace Query Language Syntax for Creating User-Defined Defects
Learn the necessary PQL syntax for creating new user-defined defects. - Polyspace Query Language Syntax for Creating User-Defined Coding Standard
Learn the syntax for creating new user defined coding standards. - Overview of Semantic Classes in Polyspace Query Language
Summary of PQL classes that are designed to detect semantic issues in your code. - Overview of Syntactic Classes in Polyspace Query Language
Summary of PQL classes that are designed to detect syntactic issues in your code.
创建您自己的标准
- Create User-Defined Coding Standard by Using Polyspace Query Language
Create new user defined defects and use these defects along with existing bug Finder checkers to create a user-defined coding standard in a sharable
.pschkfile. - Best Practices for Creating User-Defined Coding Standards
Organize user-defined coding standards in modular packages for easier maintenance.
创建您自己的缺陷
- Detect Semantic Issues Using Polyspace Query Language Semantic Classes
Create a new user-defined defect that checks for a semantic issue. - Detect Syntactic Issues Using Polyspace Query Language Syntactic Classes
Create a new user-defined defect that checks for a syntactic issue. - Implement Exceptions in User-Defined Defects
Define exceptions to your defects by using theexceptstatement. - Unit Test User-Defined Defects
Run unit tests on defects or rules that passes if the expected violations are present. - Choose Between Semantic and Syntactic Classes
Identify which PQL classes fit your use cases. - Traverse Syntax Tree Using Polyspace Query Language
Learn how you can use PQL to traverse the syntax tree and find a specific syntax node. - Best Practice for Defining User-Defined Defect Checkers
Create performant user-defined defects that are easier to test and maintain.
精选示例
Detect typedef of typedefs
Implement a rule that reports a violation when already define types are used in
typedef.
Detect Functions with Return Immediately Discarded
Implement a rule that reports a violation when return value of a function with at least one input is immediately discarded.
Detect Implicit Casts with Precision Loss
Implement a rule that reports a violation when an implicit cast results in precision loss.
Detect Multiline Comments That Start on an Expression Line
Implement a rule about location of comments using Polyspace query language.
Detect Use of std Namespace in using Declaration
Implement a rule that reports a violation on using namespace
std.
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
选择网站
选择网站以获取翻译的可用内容,以及查看当地活动和优惠。根据您的位置,我们建议您选择:。
您也可以从以下列表中选择网站:
如何获得最佳网站性能
选择中国网站(中文或英文)以获得最佳网站性能。其他 MathWorks 国家/地区网站并未针对您所在位置的访问进行优化。
美洲
- América Latina (Español)
- Canada (English)
- United States (English)
欧洲
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
