Skip to main content

module lang::php::ast::NormalizeAST

rascal-0.40.17
php-analysis-0.2.4

Usage

import lang::php::ast::NormalizeAST;

Source code

http://github.com/cwi-swat/php-analysis/blob/main/src/main/rascal/lang/php/ast/NormalizeAST.rsc

Dependencies

import lang::php::ast::AbstractSyntax;
import List;
import Node;
import String;

data Expr

data Expr  
= blockedVar(NameOrExpr varName)
;

function oldNamespaces

Script oldNamespaces(Script s)

function createIf

Stmt createIf(ElseIf e:elseIf(Expr cond, list[Stmt] body), OptionElse oe)

function normalizeIf

Script normalizeIf(Script s)

function flattenBlocks

Script flattenBlocks(Script s)

function discardEmpties

Script discardEmpties(Script s)

function useBuiltins

Script useBuiltins(Script s)

function discardHTML

Script discardHTML(Script s)

function mergeHTML

Script mergeHTML(Script s)

function discardScalarContents

Script discardScalarContents(Script s)

function normalizeArrayAccesses

Script normalizeArrayAccesses(Script s)

function replaceBlockedVars

Script replaceBlockedVars(Script s)

function switchNamespaceSeparators

Script switchNamespaceSeparators(Script s)

function normalizeEncapsedStrings

Script normalizeEncapsedStrings(Script s)

function discardModifiers

Script discardModifiers(Script s)

function addPublicModifierWhenNotProvided

Script addPublicModifierWhenNotProvided(Script s)

function discardAnnotations

Script discardAnnotations(Script s)