clang 20.0.0git
|
#include "clang/Sema/SemaWasm.h"
Public Member Functions | |
SemaWasm (Sema &S) | |
bool | CheckWebAssemblyBuiltinFunctionCall (const TargetInfo &TI, unsigned BuiltinID, CallExpr *TheCall) |
bool | BuiltinWasmRefNullExtern (CallExpr *TheCall) |
bool | BuiltinWasmRefNullFunc (CallExpr *TheCall) |
bool | BuiltinWasmTableGet (CallExpr *TheCall) |
Check that the first argument is a WebAssembly table, and the second is an index to use as index into the table. | |
bool | BuiltinWasmTableSet (CallExpr *TheCall) |
Check that the first argumnet is a WebAssembly table, the second is an index to use as index into the table and the third is the reference type to set into the table. | |
bool | BuiltinWasmTableSize (CallExpr *TheCall) |
Check that the argument is a WebAssembly table. | |
bool | BuiltinWasmTableGrow (CallExpr *TheCall) |
Check that the first argument is a WebAssembly table, the second is the value to use for new elements (of a type matching the table type), the third value is an integer. | |
bool | BuiltinWasmTableFill (CallExpr *TheCall) |
Check that the first argument is a WebAssembly table, the second is an integer, the third is the value to use to fill the table (of a type matching the table type), and the fourth is an integer. | |
bool | BuiltinWasmTableCopy (CallExpr *TheCall) |
Check that the first argument is a WebAssembly table, the second is also a WebAssembly table (of the same element type), and the third to fifth arguments are integers. | |
WebAssemblyImportNameAttr * | mergeImportNameAttr (Decl *D, const WebAssemblyImportNameAttr &AL) |
WebAssemblyImportModuleAttr * | mergeImportModuleAttr (Decl *D, const WebAssemblyImportModuleAttr &AL) |
void | handleWebAssemblyExportNameAttr (Decl *D, const ParsedAttr &AL) |
void | handleWebAssemblyImportModuleAttr (Decl *D, const ParsedAttr &AL) |
void | handleWebAssemblyImportNameAttr (Decl *D, const ParsedAttr &AL) |
Public Member Functions inherited from clang::SemaBase | |
SemaBase (Sema &S) | |
ASTContext & | getASTContext () const |
DiagnosticsEngine & | getDiagnostics () const |
const LangOptions & | getLangOpts () const |
SemaDiagnosticBuilder | Diag (SourceLocation Loc, unsigned DiagID, bool DeferHint=false) |
Emit a diagnostic. | |
SemaDiagnosticBuilder | Diag (SourceLocation Loc, const PartialDiagnostic &PD, bool DeferHint=false) |
Emit a partial diagnostic. | |
PartialDiagnostic | PDiag (unsigned DiagID=0) |
Build a partial diagnostic. | |
Additional Inherited Members | |
Public Attributes inherited from clang::SemaBase | |
Sema & | SemaRef |
Definition at line 23 of file SemaWasm.h.
clang::SemaWasm::SemaWasm | ( | Sema & | S | ) |
Definition at line 25 of file SemaWasm.cpp.
Definition at line 54 of file SemaWasm.cpp.
References clang::SemaBase::getASTContext(), clang::CallExpr::getNumArgs(), and clang::Expr::setType().
Referenced by CheckWebAssemblyBuiltinFunctionCall().
Definition at line 63 of file SemaWasm.cpp.
References clang::SemaBase::Diag(), clang::SemaBase::getASTContext(), clang::CallExpr::getBeginLoc(), clang::CallExpr::getNumArgs(), clang::Expr::setType(), and clang::wasm_funcref.
Referenced by CheckWebAssemblyBuiltinFunctionCall().
Check that the first argument is a WebAssembly table, the second is also a WebAssembly table (of the same element type), and the third to fifth arguments are integers.
Definition at line 192 of file SemaWasm.cpp.
References clang::Sema::checkArgCount(), clang::CheckWasmBuiltinArgIsInteger(), clang::CheckWasmBuiltinArgIsTable(), clang::SemaBase::Diag(), clang::CallExpr::getArg(), clang::SemaBase::getASTContext(), clang::Stmt::getBeginLoc(), clang::Stmt::getSourceRange(), and clang::SemaBase::SemaRef.
Referenced by CheckWebAssemblyBuiltinFunctionCall().
Check that the first argument is a WebAssembly table, the second is an integer, the third is the value to use to fill the table (of a type matching the table type), and the fourth is an integer.
Definition at line 165 of file SemaWasm.cpp.
References clang::Sema::checkArgCount(), clang::CheckWasmBuiltinArgIsInteger(), clang::CheckWasmBuiltinArgIsTable(), clang::SemaBase::Diag(), clang::CallExpr::getArg(), clang::SemaBase::getASTContext(), clang::Stmt::getBeginLoc(), clang::Stmt::getSourceRange(), clang::Expr::getType(), and clang::SemaBase::SemaRef.
Referenced by CheckWebAssemblyBuiltinFunctionCall().
Check that the first argument is a WebAssembly table, and the second is an index to use as index into the table.
Definition at line 86 of file SemaWasm.cpp.
References clang::Sema::checkArgCount(), clang::CheckWasmBuiltinArgIsInteger(), clang::CheckWasmBuiltinArgIsTable(), clang::SemaBase::SemaRef, and clang::Expr::setType().
Referenced by CheckWebAssemblyBuiltinFunctionCall().
Check that the first argument is a WebAssembly table, the second is the value to use for new elements (of a type matching the table type), the third value is an integer.
Definition at line 141 of file SemaWasm.cpp.
References clang::Sema::checkArgCount(), clang::CheckWasmBuiltinArgIsInteger(), clang::CheckWasmBuiltinArgIsTable(), clang::SemaBase::Diag(), clang::CallExpr::getArg(), clang::SemaBase::getASTContext(), clang::Stmt::getBeginLoc(), clang::Stmt::getSourceRange(), clang::Expr::getType(), and clang::SemaBase::SemaRef.
Referenced by CheckWebAssemblyBuiltinFunctionCall().
Check that the first argumnet is a WebAssembly table, the second is an index to use as index into the table and the third is the reference type to set into the table.
Definition at line 109 of file SemaWasm.cpp.
References clang::Sema::checkArgCount(), clang::CheckWasmBuiltinArgIsInteger(), clang::CheckWasmBuiltinArgIsTable(), clang::CallExpr::getArg(), clang::SemaBase::getASTContext(), clang::Expr::getType(), and clang::SemaBase::SemaRef.
Referenced by CheckWebAssemblyBuiltinFunctionCall().
Check that the argument is a WebAssembly table.
Definition at line 127 of file SemaWasm.cpp.
References clang::Sema::checkArgCount(), clang::CheckWasmBuiltinArgIsTable(), and clang::SemaBase::SemaRef.
Referenced by CheckWebAssemblyBuiltinFunctionCall().
bool clang::SemaWasm::CheckWebAssemblyBuiltinFunctionCall | ( | const TargetInfo & | TI, |
unsigned | BuiltinID, | ||
CallExpr * | TheCall | ||
) |
Definition at line 219 of file SemaWasm.cpp.
References BuiltinWasmRefNullExtern(), BuiltinWasmRefNullFunc(), BuiltinWasmTableCopy(), BuiltinWasmTableFill(), BuiltinWasmTableGet(), BuiltinWasmTableGrow(), BuiltinWasmTableSet(), and BuiltinWasmTableSize().
void clang::SemaWasm::handleWebAssemblyExportNameAttr | ( | Decl * | D, |
const ParsedAttr & | AL | ||
) |
Definition at line 318 of file SemaWasm.cpp.
References clang::Sema::checkStringLiteralArgumentAttr(), D, clang::SemaBase::Diag(), clang::ExpectedFunction, clang::SemaBase::getASTContext(), clang::isFuncOrMethodForAttrSubject(), clang::AttributeCommonInfo::isRegularKeywordAttribute(), and clang::SemaBase::SemaRef.
Referenced by ProcessDeclAttribute().
void clang::SemaWasm::handleWebAssemblyImportModuleAttr | ( | Decl * | D, |
const ParsedAttr & | AL | ||
) |
Definition at line 285 of file SemaWasm.cpp.
References clang::Sema::checkStringLiteralArgumentAttr(), D, clang::SemaBase::Diag(), clang::SemaBase::getASTContext(), clang::AttributeCommonInfo::getLoc(), and clang::SemaBase::SemaRef.
Referenced by ProcessDeclAttribute().
void clang::SemaWasm::handleWebAssemblyImportNameAttr | ( | Decl * | D, |
const ParsedAttr & | AL | ||
) |
Definition at line 302 of file SemaWasm.cpp.
References clang::Sema::checkStringLiteralArgumentAttr(), D, clang::SemaBase::Diag(), clang::SemaBase::getASTContext(), clang::AttributeCommonInfo::getLoc(), and clang::SemaBase::SemaRef.
Referenced by ProcessDeclAttribute().
WebAssemblyImportModuleAttr * clang::SemaWasm::mergeImportModuleAttr | ( | Decl * | D, |
const WebAssemblyImportModuleAttr & | AL | ||
) |
Definition at line 245 of file SemaWasm.cpp.
References D, clang::SemaBase::Diag(), and clang::SemaBase::getASTContext().
Referenced by mergeDeclAttribute().
WebAssemblyImportNameAttr * clang::SemaWasm::mergeImportNameAttr | ( | Decl * | D, |
const WebAssemblyImportNameAttr & | AL | ||
) |
Definition at line 266 of file SemaWasm.cpp.
References D, clang::SemaBase::Diag(), and clang::SemaBase::getASTContext().
Referenced by mergeDeclAttribute().