The definition of a property

Introduced properties

type MPROPDEF: MPropDef

nitc :: APropdef :: MPROPDEF

The associated main model entity
private var _after_flow_context: nullable FlowContext

nitc :: APropdef :: _after_flow_context

The ending flow
private var _basic_block: nullable BasicBlock

nitc :: APropdef :: _basic_block

The first basic block of the code
private var _before_flow_context: nullable FlowContext

nitc :: APropdef :: _before_flow_context

The starting flow
private var _environment_size: Int

nitc :: APropdef :: _environment_size

The size of the environment to create to call this method
private var _is_compiled: Bool

nitc :: APropdef :: _is_compiled

Indicite if this propdef was compile
private var _is_generated: Bool

nitc :: APropdef :: _is_generated

If true, the basic blocks where generated
private var _is_numbering: Bool

nitc :: APropdef :: _is_numbering

Indicate if the variables numbering has been done
private var _is_phased: Bool

nitc :: APropdef :: _is_phased

Is the propdef already analyzed by run_phases_on_npropdef.
private var _mpropdef: nullable MPROPDEF

nitc :: APropdef :: _mpropdef

The associated propdef once build by a ModelBuilder
private var _object_sites: Array[AExpr]

nitc :: APropdef :: _object_sites

Contain all AST-parts related to object mechanisms the propdef has:
private var _return_mark: nullable EscapeMark

nitc :: APropdef :: _return_mark

The break escape mark associated with the return
private var _returnvar: Variable

nitc :: APropdef :: _returnvar

The return variable of the propdef
private var _selfvariable: nullable Variable

nitc :: APropdef :: _selfvariable

The variable associated to the receiver (if any)
private var _variables: HashSet[Variable]

nitc :: APropdef :: _variables

The variables contained in the body on this propdef
fun after_flow_context: nullable FlowContext

nitc :: APropdef :: after_flow_context

The ending flow
protected fun after_flow_context=(after_flow_context: nullable FlowContext)

nitc :: APropdef :: after_flow_context=

The ending flow
fun basic_block: nullable BasicBlock

nitc :: APropdef :: basic_block

The first basic block of the code
protected fun basic_block=(basic_block: nullable BasicBlock)

nitc :: APropdef :: basic_block=

The first basic block of the code
fun before_flow_context: nullable FlowContext

nitc :: APropdef :: before_flow_context

The starting flow
protected fun before_flow_context=(before_flow_context: nullable FlowContext)

nitc :: APropdef :: before_flow_context=

The starting flow
private fun build_property(modelbuilder: ModelBuilder, mclassdef: MClassDef)

nitc :: APropdef :: build_property

private fun build_signature(modelbuilder: ModelBuilder)

nitc :: APropdef :: build_signature

private fun call(v: NaiveInterpreter, mpropdef: MMethodDef, args: Array[Instance]): nullable Instance

nitc :: APropdef :: call

Execute a mpropdef associated with the current node.
private fun check_redef_keyword(modelbuilder: ModelBuilder, mclassdef: MClassDef, kwredef: nullable Token, need_redef: Bool, mprop: MProperty): Bool

nitc :: APropdef :: check_redef_keyword

private fun check_redef_property_visibility(modelbuilder: ModelBuilder, nvisibility: nullable AVisibility, mprop: MProperty)

nitc :: APropdef :: check_redef_property_visibility

private fun check_repeated_types(modelbuilder: ModelBuilder)

nitc :: APropdef :: check_repeated_types

Checks for useless type in redef signatures.
private fun check_signature(modelbuilder: ModelBuilder)

nitc :: APropdef :: check_signature

fun compile(vm: VirtualMachine)

nitc :: APropdef :: compile

Compile this propdef
fun compile_to_java(v: JavaCompilerVisitor, mpropdef: MMethodDef, arguments: Array[RuntimeVariable])

nitc :: APropdef :: compile_to_java

Compile that property definition to java code
fun compute_phi(ssa: SSA)

nitc :: APropdef :: compute_phi

Compute the first phase of SSA algorithm: placing phi-functions
fun compute_ssa(ssa: SSA)

nitc :: APropdef :: compute_ssa

Compute the three steps of SSA-algorithm
fun do_flow(toolcontext: ToolContext)

nitc :: APropdef :: do_flow

The entry point of the whole flow analysis
fun do_local_var_init(toolcontext: ToolContext)

nitc :: APropdef :: do_local_var_init

Entry point of the whole local variable initialization verifier
fun do_scope(toolcontext: ToolContext)

nitc :: APropdef :: do_scope

Entry point of the scope analysis
fun do_typing(modelbuilder: ModelBuilder)

nitc :: APropdef :: do_typing

The entry point of the whole typing analysis
private fun environment_size: Int

nitc :: APropdef :: environment_size

The size of the environment to create to call this method
private fun environment_size=(environment_size: Int)

nitc :: APropdef :: environment_size=

The size of the environment to create to call this method
abstract fun generate_basic_blocks(ssa: SSA)

nitc :: APropdef :: generate_basic_blocks

Generate all basic blocks for this code
fun generate_name(v: Variable, counter: HashMap[Variable, Int], expr: ANode, ssa: SSA): Variable

nitc :: APropdef :: generate_name

Generate a new version of the variable v and return it
fun is_compiled: Bool

nitc :: APropdef :: is_compiled

Indicite if this propdef was compile
protected fun is_compiled=(is_compiled: Bool)

nitc :: APropdef :: is_compiled=

Indicite if this propdef was compile
fun is_generated: Bool

nitc :: APropdef :: is_generated

If true, the basic blocks where generated
protected fun is_generated=(is_generated: Bool)

nitc :: APropdef :: is_generated=

If true, the basic blocks where generated
private fun is_numbering: Bool

nitc :: APropdef :: is_numbering

Indicate if the variables numbering has been done
private fun is_numbering=(is_numbering: Bool)

nitc :: APropdef :: is_numbering=

Indicate if the variables numbering has been done
private fun is_phased: Bool

nitc :: APropdef :: is_phased

Is the propdef already analyzed by run_phases_on_npropdef.
private fun is_phased=(is_phased: Bool)

nitc :: APropdef :: is_phased=

Is the propdef already analyzed by run_phases_on_npropdef.
fun mpropdef: nullable MPROPDEF

nitc :: APropdef :: mpropdef

The associated propdef once build by a ModelBuilder
fun mpropdef=(mpropdef: nullable MPROPDEF)

nitc :: APropdef :: mpropdef=

The associated propdef once build by a ModelBuilder
private fun new_property_visibility(modelbuilder: ModelBuilder, mclassdef: MClassDef, nvisibility: nullable AVisibility): MVisibility

nitc :: APropdef :: new_property_visibility

abstract fun numbering_variables(vm: VirtualMachine)

nitc :: APropdef :: numbering_variables

Numbering the variable inside the propdef
fun object_sites: Array[AExpr]

nitc :: APropdef :: object_sites

Contain all AST-parts related to object mechanisms the propdef has:
protected fun object_sites=(object_sites: Array[AExpr])

nitc :: APropdef :: object_sites=

Contain all AST-parts related to object mechanisms the propdef has:
fun propagate_dependences(phi: PhiFunction, block: BasicBlock)

nitc :: APropdef :: propagate_dependences

Propagate the dependences of the phi-functions into following variables
fun rename(block: BasicBlock, counter: HashMap[Variable, Int], ssa: SSA)

nitc :: APropdef :: rename

Recursively rename each variable from block
fun rename_variables(ssa: SSA)

nitc :: APropdef :: rename_variables

Compute the second phase of SSA algorithm: renaming variables
fun return_mark: nullable EscapeMark

nitc :: APropdef :: return_mark

The break escape mark associated with the return
protected fun return_mark=(return_mark: nullable EscapeMark)

nitc :: APropdef :: return_mark=

The break escape mark associated with the return
fun returnvar: Variable

nitc :: APropdef :: returnvar

The return variable of the propdef
protected fun returnvar=(returnvar: Variable)

nitc :: APropdef :: returnvar=

The return variable of the propdef
fun selfvariable: nullable Variable

nitc :: APropdef :: selfvariable

The variable associated to the receiver (if any)
protected fun selfvariable=(selfvariable: nullable Variable)

nitc :: APropdef :: selfvariable=

The variable associated to the receiver (if any)
private fun set_doc(mpropdef: MPropDef, modelbuilder: ModelBuilder)

nitc :: APropdef :: set_doc

fun ssa_destruction(ssa: SSA)

nitc :: APropdef :: ssa_destruction

Transform SSA-representation into an executable code (delete phi-functions)
private fun tag(mpd: MPropDef): HTMLTag

nitc :: APropdef :: tag

fun variables: HashSet[Variable]

nitc :: APropdef :: variables

The variables contained in the body on this propdef
protected fun variables=(variables: HashSet[Variable])

nitc :: APropdef :: variables=

The variables contained in the body on this propdef
fun visit_annotations(v: PrettyPrinterVisitor, n_annotations: nullable AAnnotations): Bool

nitc :: APropdef :: visit_annotations

Factorize annotations visit for all APropdef.
fun visit_block(v: PrettyPrinterVisitor, n_block: nullable AExpr, annot_inline: Bool)

nitc :: APropdef :: visit_block

Factorize block visit for APropdefs.

Redefined properties

redef type SELF: APropdef

nitc $ APropdef :: SELF

Type of this instance, automatically specialized in every class
redef fun accept_pretty_printer(v: PrettyPrinterVisitor)

nitc :: pretty $ APropdef :: accept_pretty_printer

Start visit of self using a PrettyPrinterVisitor
redef fun compile(vm: VirtualMachine)

nitc :: compilation $ APropdef :: compile

Compile this propdef
redef fun generate_name(v: Variable, counter: HashMap[Variable, Int], expr: ANode, ssa: SSA): Variable

nitc :: compilation $ APropdef :: generate_name

Redef to add the same position to a new version of a Variable than the original variable
redef fun make_tag(v: HtmlightVisitor): nullable HTMLTag

nitc :: htmlight $ APropdef :: make_tag

Optionally creates a tag that encapsulate the AST element on HTML rendering
redef fun start_token: nullable Token

nitc :: pretty $ APropdef :: start_token

The token where the production really start (skipping ADoc).

All properties

fun !=(other: nullable Object): Bool

core :: Object :: !=

Have self and other different values?
fun ==(other: nullable Object): Bool

core :: Object :: ==

Have self and other the same value?
type CLASS: Class[SELF]

core :: Object :: CLASS

The type of the class of self.
type MPROPDEF: MPropDef

nitc :: APropdef :: MPROPDEF

The associated main model entity
type SELF: Object

core :: Object :: SELF

Type of this instance, automatically specialized in every class
private var _after_flow_context: nullable FlowContext

nitc :: APropdef :: _after_flow_context

The ending flow
private var _basic_block: nullable BasicBlock

nitc :: APropdef :: _basic_block

The first basic block of the code
private var _before_flow_context: nullable FlowContext

nitc :: APropdef :: _before_flow_context

The starting flow
private var _environment_size: Int

nitc :: APropdef :: _environment_size

The size of the environment to create to call this method
private var _first_location: nullable Location

nitc :: Prod :: _first_location

Location on the first token after the start of a production
private var _first_token: nullable Token

nitc :: Prod :: _first_token

The first token of the production in the AST
private var _force_block: Bool

nitc :: ANode :: _force_block

Force self to be rendered as a block.
private var _force_inline: Bool

nitc :: ANode :: _force_inline

Force self to be rendered as a line.
private var _is_broken: Bool

nitc :: ANode :: _is_broken

The indication that the node did not pass some semantic verifications.
private var _is_compiled: Bool

nitc :: APropdef :: _is_compiled

Indicite if this propdef was compile
private var _is_generated: Bool

nitc :: APropdef :: _is_generated

If true, the basic blocks where generated
private var _is_numbering: Bool

nitc :: APropdef :: _is_numbering

Indicate if the variables numbering has been done
private var _is_phased: Bool

nitc :: APropdef :: _is_phased

Is the propdef already analyzed by run_phases_on_npropdef.
private var _last_token: nullable Token

nitc :: Prod :: _last_token

The last token of the production in the AST
private var _location: Location

nitc :: ANode :: _location

Location is set during AST building. Once built, location can not be null.
private var _mpropdef: nullable MPROPDEF

nitc :: APropdef :: _mpropdef

The associated propdef once build by a ModelBuilder
private var _n_annotations: nullable AAnnotations

nitc :: Prod :: _n_annotations

All the annotations attached directly to the node
private var _n_doc: nullable ADoc

nitc :: ADefinition :: _n_doc

The documentation
private var _n_kwredef: nullable TKwredef

nitc :: ADefinition :: _n_kwredef

The redef keyword
private var _n_visibility: nullable AVisibility

nitc :: ADefinition :: _n_visibility

The declared visibility
private var _object_sites: Array[AExpr]

nitc :: APropdef :: _object_sites

Contain all AST-parts related to object mechanisms the propdef has:
private var _parent: nullable ANode

nitc :: ANode :: _parent

Parent of the node in the AST
private var _return_mark: nullable EscapeMark

nitc :: APropdef :: _return_mark

The break escape mark associated with the return
private var _returnvar: Variable

nitc :: APropdef :: _returnvar

The return variable of the propdef
private var _selfvariable: nullable Variable

nitc :: APropdef :: _selfvariable

The variable associated to the receiver (if any)
private var _variables: HashSet[Variable]

nitc :: APropdef :: _variables

The variables contained in the body on this propdef
fun accept_forward_analysis(v: ForwardAnalysis)

nitc :: ANode :: accept_forward_analysis

Apply the forward analysis v to self.
private abstract fun accept_pretty_printer(v: PrettyPrinterVisitor)

nitc :: ANode :: accept_pretty_printer

Start visit of self using a PrettyPrinterVisitor
fun accept_reaching_defs(v: ReachingDefsAnalysis)

nitc :: ANode :: accept_reaching_defs

Apply a ReachingDefsAnalysis to self.
fun after_flow_context: nullable FlowContext

nitc :: APropdef :: after_flow_context

The ending flow
protected fun after_flow_context=(after_flow_context: nullable FlowContext)

nitc :: APropdef :: after_flow_context=

The ending flow
private fun bad_expr_message(child: AExpr): nullable String

nitc :: ANode :: bad_expr_message

An additional information message to explain the role of a child expression.
fun basic_block: nullable BasicBlock

nitc :: APropdef :: basic_block

The first basic block of the code
protected fun basic_block=(basic_block: nullable BasicBlock)

nitc :: APropdef :: basic_block=

The first basic block of the code
fun before_flow_context: nullable FlowContext

nitc :: APropdef :: before_flow_context

The starting flow
protected fun before_flow_context=(before_flow_context: nullable FlowContext)

nitc :: APropdef :: before_flow_context=

The starting flow
private fun build_property(modelbuilder: ModelBuilder, mclassdef: MClassDef)

nitc :: APropdef :: build_property

private fun build_signature(modelbuilder: ModelBuilder)

nitc :: APropdef :: build_signature

private fun call(v: NaiveInterpreter, mpropdef: MMethodDef, args: Array[Instance]): nullable Instance

nitc :: APropdef :: call

Execute a mpropdef associated with the current node.
private fun check_redef_keyword(modelbuilder: ModelBuilder, mclassdef: MClassDef, kwredef: nullable Token, need_redef: Bool, mprop: MProperty): Bool

nitc :: APropdef :: check_redef_keyword

private fun check_redef_property_visibility(modelbuilder: ModelBuilder, nvisibility: nullable AVisibility, mprop: MProperty)

nitc :: APropdef :: check_redef_property_visibility

private fun check_repeated_types(modelbuilder: ModelBuilder)

nitc :: APropdef :: check_repeated_types

Checks for useless type in redef signatures.
private fun check_signature(modelbuilder: ModelBuilder)

nitc :: APropdef :: check_signature

protected fun class_factory(name: String): CLASS

core :: Object :: class_factory

Implementation used by get_class to create the specific class.
fun class_name: String

core :: Object :: class_name

The class name of the object.
abstract fun clone: SELF

core :: Cloneable :: clone

Duplicate self
fun collect_annotations_by_name(name: String): Array[AAnnotation]

nitc :: ANode :: collect_annotations_by_name

Do a deep search and return an array of node that are annotated
private fun collect_comments: Array[TComment]

nitc :: Prod :: collect_comments

Collect all TComment contained in the production
private abstract fun collect_length: Int

nitc :: ANode :: collect_length

Collect the length (in Char) of the node.
fun collect_text: String

nitc :: Prod :: collect_text

Join the text of all visited tokens
fun collect_tokens_by_text(text: String): Array[Token]

nitc :: ANode :: collect_tokens_by_text

Do a deep search and return an array of tokens that match a given text
fun common_parent(other: ANode): nullable ANode

nitc :: ANode :: common_parent

The most specific common parent between self and other
fun compile(vm: VirtualMachine)

nitc :: APropdef :: compile

Compile this propdef
fun compile_to_java(v: JavaCompilerVisitor, mpropdef: MMethodDef, arguments: Array[RuntimeVariable])

nitc :: APropdef :: compile_to_java

Compile that property definition to java code
fun compute_phi(ssa: SSA)

nitc :: APropdef :: compute_phi

Compute the first phase of SSA algorithm: placing phi-functions
fun compute_ssa(ssa: SSA)

nitc :: APropdef :: compute_ssa

Compute the three steps of SSA-algorithm
fun debug(message: String)

nitc :: ANode :: debug

Display a message for the colored location of the node
protected fun decorate_tag(v: HtmlightVisitor, res: HTMLTag, token: Token): nullable HInfoBox

nitc :: ANode :: decorate_tag

Add aditionnal information on a child-token and return an additionnal HInfoBox on it
fun depth: Int

nitc :: ANode :: depth

Number of nodes between self and the root of the AST
fun detach

nitc :: ANode :: detach

Detach a node from its parent
private fun do_cloneable(v: CloneVisitor)

nitc :: ANode :: do_cloneable

fun do_flow(toolcontext: ToolContext)

nitc :: APropdef :: do_flow

The entry point of the whole flow analysis
fun do_local_var_init(toolcontext: ToolContext)

nitc :: APropdef :: do_local_var_init

Entry point of the whole local variable initialization verifier
fun do_scope(toolcontext: ToolContext)

nitc :: APropdef :: do_scope

Entry point of the scope analysis
fun do_typing(modelbuilder: ModelBuilder)

nitc :: APropdef :: do_typing

The entry point of the whole typing analysis
fun dump_info(v: ASTDump): String

nitc :: ANode :: dump_info

Information to display on a node
fun dump_tree(display_structural: nullable Bool, display_line: nullable Bool)

nitc :: ANode :: dump_tree

Write the subtree on stdout.
private fun environment_size: Int

nitc :: APropdef :: environment_size

The size of the environment to create to call this method
private fun environment_size=(environment_size: Int)

nitc :: APropdef :: environment_size=

The size of the environment to create to call this method
fun fatal(v: NaiveInterpreter, message: String)

nitc :: ANode :: fatal

Aborts the program with a message
fun first_location: nullable Location

nitc :: Prod :: first_location

Location on the first token after the start of a production
protected fun first_location=(first_location: nullable Location)

nitc :: Prod :: first_location=

Location on the first token after the start of a production
fun first_token: nullable Token

nitc :: Prod :: first_token

The first token of the production in the AST
protected fun first_token=(first_token: nullable Token)

nitc :: Prod :: first_token=

The first token of the production in the AST
private fun force_block: Bool

nitc :: ANode :: force_block

Force self to be rendered as a block.
private fun force_block=(force_block: Bool)

nitc :: ANode :: force_block=

Force self to be rendered as a block.
private fun force_inline: Bool

nitc :: ANode :: force_inline

Force self to be rendered as a line.
private fun force_inline=(force_inline: Bool)

nitc :: ANode :: force_inline=

Force self to be rendered as a line.
abstract fun generate_basic_blocks(ssa: SSA)

nitc :: APropdef :: generate_basic_blocks

Generate all basic blocks for this code
fun generate_name(v: Variable, counter: HashMap[Variable, Int], expr: ANode, ssa: SSA): Variable

nitc :: APropdef :: generate_name

Generate a new version of the variable v and return it
fun get_annotations(name: String): Array[AAnnotation]

nitc :: Prod :: get_annotations

Return all its annotations of a given name in the order of their declaration
fun get_class: CLASS

core :: Object :: get_class

The meta-object representing the dynamic type of self.
fun get_single_annotation(name: String, modelbuilder: ModelBuilder): nullable AAnnotation

nitc :: Prod :: get_single_annotation

Try to get its single annotation with a given name
fun hash: Int

core :: Object :: hash

The hash code of the object.
fun hot_location: Location

nitc :: ANode :: hot_location

The location of the important part of the node (identifier or whatever)
fun infobox(v: HtmlightVisitor): nullable HInfoBox

nitc :: ANode :: infobox

Return a optional infobox
init init

core :: Object :: init

fun inspect: String

core :: Object :: inspect

Developer readable representation of self.
protected fun inspect_head: String

core :: Object :: inspect_head

Return "CLASSNAME:#OBJECTID".
fun is_block: Bool

nitc :: Prod :: is_block

Is the production contained in full block of line?
fun is_broken: Bool

nitc :: ANode :: is_broken

The indication that the node did not pass some semantic verifications.
fun is_broken=(is_broken: Bool)

nitc :: ANode :: is_broken=

The indication that the node did not pass some semantic verifications.
fun is_compiled: Bool

nitc :: APropdef :: is_compiled

Indicite if this propdef was compile
protected fun is_compiled=(is_compiled: Bool)

nitc :: APropdef :: is_compiled=

Indicite if this propdef was compile
fun is_generated: Bool

nitc :: APropdef :: is_generated

If true, the basic blocks where generated
protected fun is_generated=(is_generated: Bool)

nitc :: APropdef :: is_generated=

If true, the basic blocks where generated
private fun is_inlinable: Bool

nitc :: ANode :: is_inlinable

Is self printable in one line?
private fun is_noserialize: Bool

nitc :: ANode :: is_noserialize

Is this node annotated to not be made serializable?
private fun is_numbering: Bool

nitc :: APropdef :: is_numbering

Indicate if the variables numbering has been done
private fun is_numbering=(is_numbering: Bool)

nitc :: APropdef :: is_numbering=

Indicate if the variables numbering has been done
private fun is_phased: Bool

nitc :: APropdef :: is_phased

Is the propdef already analyzed by run_phases_on_npropdef.
private fun is_phased=(is_phased: Bool)

nitc :: APropdef :: is_phased=

Is the propdef already analyzed by run_phases_on_npropdef.
intern fun is_same_instance(other: nullable Object): Bool

core :: Object :: is_same_instance

Return true if self and other are the same instance (i.e. same identity).
fun is_same_serialized(other: nullable Object): Bool

core :: Object :: is_same_serialized

Is self the same as other in a serialization context?
intern fun is_same_type(other: Object): Bool

core :: Object :: is_same_type

Return true if self and other have the same dynamic type.
private fun is_serialize: Bool

nitc :: ANode :: is_serialize

Is this node annotated to be made serializable?
fun is_span: Bool

nitc :: Prod :: is_span

Is the production a part of a single line (without being a block)
fun is_structural: Bool

nitc :: ANode :: is_structural

Is self a token or a pure-structural production like AQId?
fun last_token: nullable Token

nitc :: Prod :: last_token

The last token of the production in the AST
protected fun last_token=(last_token: nullable Token)

nitc :: Prod :: last_token=

The last token of the production in the AST
fun location: Location

nitc :: ANode :: location

Location is set during AST building. Once built, location can not be null.
fun location=(location: Location)

nitc :: ANode :: location=

Location is set during AST building. Once built, location can not be null.
protected fun make_tag(v: HtmlightVisitor): nullable HTMLTag

nitc :: ANode :: make_tag

Optionally creates a tag that encapsulate the AST element on HTML rendering
fun mpropdef: nullable MPROPDEF

nitc :: APropdef :: mpropdef

The associated propdef once build by a ModelBuilder
fun mpropdef=(mpropdef: nullable MPROPDEF)

nitc :: APropdef :: mpropdef=

The associated propdef once build by a ModelBuilder
private fun must_be_block: Bool

nitc :: ANode :: must_be_block

Does self have to be rendered as a block?
private fun must_be_inline: Bool

nitc :: ANode :: must_be_inline

Does self have be rendered as a line?
fun n_annotations: nullable AAnnotations

nitc :: Prod :: n_annotations

All the annotations attached directly to the node
fun n_annotations=(n_annotations: nullable AAnnotations)

nitc :: Prod :: n_annotations=

All the annotations attached directly to the node
fun n_doc: nullable ADoc

nitc :: ADefinition :: n_doc

The documentation
fun n_doc=(n_doc: nullable ADoc)

nitc :: ADefinition :: n_doc=

The documentation
fun n_kwredef: nullable TKwredef

nitc :: ADefinition :: n_kwredef

The redef keyword
fun n_kwredef=(n_kwredef: nullable TKwredef)

nitc :: ADefinition :: n_kwredef=

The redef keyword
fun n_visibility: nullable AVisibility

nitc :: ADefinition :: n_visibility

The declared visibility
fun n_visibility=(n_visibility: nullable AVisibility)

nitc :: ADefinition :: n_visibility=

The declared visibility
private intern fun native_class_name: CString

core :: Object :: native_class_name

The class name of the object in CString format.
private fun new_property_visibility(modelbuilder: ModelBuilder, mclassdef: MClassDef, nvisibility: nullable AVisibility): MVisibility

nitc :: APropdef :: new_property_visibility

abstract fun numbering_variables(vm: VirtualMachine)

nitc :: APropdef :: numbering_variables

Numbering the variable inside the propdef
intern fun object_id: Int

core :: Object :: object_id

An internal hash code for the object based on its identity.
fun object_sites: Array[AExpr]

nitc :: APropdef :: object_sites

Contain all AST-parts related to object mechanisms the propdef has:
protected fun object_sites=(object_sites: Array[AExpr])

nitc :: APropdef :: object_sites=

Contain all AST-parts related to object mechanisms the propdef has:
fun output

core :: Object :: output

Display self on stdout (debug only).
intern fun output_class_name

core :: Object :: output_class_name

Display class name on stdout (debug only).
fun parent: nullable ANode

nitc :: ANode :: parent

Parent of the node in the AST
protected fun parent=(parent: nullable ANode)

nitc :: ANode :: parent=

Parent of the node in the AST
fun parentize_tokens

nitc :: ANode :: parentize_tokens

Visit the AST and computes advanced AST attributes on Tokens and Prod
fun propagate_dependences(phi: PhiFunction, block: BasicBlock)

nitc :: APropdef :: propagate_dependences

Propagate the dependences of the phi-functions into following variables
fun rename(block: BasicBlock, counter: HashMap[Variable, Int], ssa: SSA)

nitc :: APropdef :: rename

Recursively rename each variable from block
fun rename_variables(ssa: SSA)

nitc :: APropdef :: rename_variables

Compute the second phase of SSA algorithm: renaming variables
private abstract fun replace_child(old_child: ANode, new_child: nullable ANode)

nitc :: ANode :: replace_child

Replace a child with an other node in the AST
fun replace_clone

nitc :: ANode :: replace_clone

Create a new clone of self
fun replace_with(node: ANode)

nitc :: ANode :: replace_with

Replace itself with an other node in the AST
fun return_mark: nullable EscapeMark

nitc :: APropdef :: return_mark

The break escape mark associated with the return
protected fun return_mark=(return_mark: nullable EscapeMark)

nitc :: APropdef :: return_mark=

The break escape mark associated with the return
fun returnvar: Variable

nitc :: APropdef :: returnvar

The return variable of the propdef
protected fun returnvar=(returnvar: Variable)

nitc :: APropdef :: returnvar=

The return variable of the propdef
fun root: ANode

nitc :: ANode :: root

The topmost ancestor of the element
fun selfvariable: nullable Variable

nitc :: APropdef :: selfvariable

The variable associated to the receiver (if any)
protected fun selfvariable=(selfvariable: nullable Variable)

nitc :: APropdef :: selfvariable=

The variable associated to the receiver (if any)
fun serialization_hash: Int

core :: Object :: serialization_hash

Hash value use for serialization
private fun set_doc(mpropdef: MPropDef, modelbuilder: ModelBuilder)

nitc :: APropdef :: set_doc

fun ssa_destruction(ssa: SSA)

nitc :: APropdef :: ssa_destruction

Transform SSA-representation into an executable code (delete phi-functions)
private fun start_token: nullable Token

nitc :: Prod :: start_token

The token where the production really start (skipping ADoc).
intern fun sys: Sys

core :: Object :: sys

Return the global sys object, the only instance of the Sys class.
private fun tag(mpd: MPropDef): HTMLTag

nitc :: APropdef :: tag

abstract fun to_jvalue(env: JniEnv): JValue

core :: Object :: to_jvalue

fun to_s: String

core :: Object :: to_s

User readable representation of self.
fun to_xml: HTMLTag

nitc :: Prod :: to_xml

A XML representation of the AST
fun validate

nitc :: ANode :: validate

Recursively validate a AST node.
fun variables: HashSet[Variable]

nitc :: APropdef :: variables

The variables contained in the body on this propdef
protected fun variables=(variables: HashSet[Variable])

nitc :: APropdef :: variables=

The variables contained in the body on this propdef
abstract fun visit_all(v: Visitor)

nitc :: ANode :: visit_all

Visit all nodes in order.
fun visit_annotations(v: PrettyPrinterVisitor, n_annotations: nullable AAnnotations): Bool

nitc :: APropdef :: visit_annotations

Factorize annotations visit for all APropdef.
fun visit_block(v: PrettyPrinterVisitor, n_block: nullable AExpr, annot_inline: Bool)

nitc :: APropdef :: visit_block

Factorize block visit for APropdefs.
private abstract fun was_inline: Bool

nitc :: ANode :: was_inline

Does self was written in one line before transformation?
package_diagram nitc::APropdef APropdef nitc::ADefinition ADefinition nitc::APropdef->nitc::ADefinition nitc::Prod Prod nitc::ADefinition->nitc::Prod ...nitc::Prod ... ...nitc::Prod->nitc::Prod nitc::AAttrPropdef AAttrPropdef nitc::AAttrPropdef->nitc::APropdef nitc::AMethPropdef AMethPropdef nitc::AMethPropdef->nitc::APropdef nitc::AAnnotPropdef AAnnotPropdef nitc::AAnnotPropdef->nitc::APropdef nitc::ASuperPropdef ASuperPropdef nitc::ASuperPropdef->nitc::APropdef nitc::ATypePropdef ATypePropdef nitc::ATypePropdef->nitc::APropdef nitc::AMainMethPropdef AMainMethPropdef nitc::AMainMethPropdef->nitc::AMethPropdef nitc::AMainMethPropdef... ... nitc::AMainMethPropdef...->nitc::AMainMethPropdef

Ancestors

abstract class ANode

nitc :: ANode

Root of the AST class-hierarchy
interface Cloneable

core :: Cloneable

Something that can be cloned
interface Object

core :: Object

The root of the class hierarchy.
abstract class Prod

nitc :: Prod

Ancestor of all productions

Parents

abstract class ADefinition

nitc :: ADefinition

Abstract class for definition of entities

Children

class AAttrPropdef

nitc :: AAttrPropdef

A definition of an attribute
class AMethPropdef

nitc :: AMethPropdef

A definition of all kind of method (including constructors)
class ASuperPropdef

nitc :: ASuperPropdef

A super-class. eg super X
class ATypePropdef

nitc :: ATypePropdef

A definition of a virtual type

Descendants

class AMainMethPropdef

nitc :: AMainMethPropdef

The implicit main method

Class definitions

nitc $ APropdef
# The definition of a property
abstract class APropdef
	super ADefinition
end
src/parser/parser_nodes.nit:1364,1--1367,3

nitc :: phase $ APropdef
redef class APropdef
	# Is the propdef already analyzed by `run_phases_on_npropdef`.
	# Unused unless `semantize_is_lazy` is true.
	private var is_phased = false
end
src/phase.nit:187,1--191,3

nitc :: scope $ APropdef
redef class APropdef
	# The break escape mark associated with the return
	var return_mark: nullable EscapeMark

	# Entry point of the scope analysis
	fun do_scope(toolcontext: ToolContext)
	do
		var v = new ScopeVisitor(toolcontext, self)
		v.enter_visit(self)
		v.shift_scope
	end
end
src/semantize/scope.nit:253,1--264,3

nitc :: modelize_property $ APropdef
redef class APropdef
	# The associated main model entity
	type MPROPDEF: MPropDef

	# The associated propdef once build by a `ModelBuilder`
	var mpropdef: nullable MPROPDEF is writable

	private fun build_property(modelbuilder: ModelBuilder, mclassdef: MClassDef) do end
	private fun build_signature(modelbuilder: ModelBuilder) do end
	private fun check_signature(modelbuilder: ModelBuilder) do end
	private fun new_property_visibility(modelbuilder: ModelBuilder, mclassdef: MClassDef, nvisibility: nullable AVisibility): MVisibility
	do
		var mvisibility = public_visibility
		if nvisibility != null then
			mvisibility = nvisibility.mvisibility
			if mvisibility == intrude_visibility then
				modelbuilder.error(nvisibility, "Error: `intrude` is not a legal visibility for properties.")
				mvisibility = public_visibility
			end
		end
		if mclassdef.mclass.visibility == private_visibility then
			if mvisibility == protected_visibility then
				assert nvisibility != null
				modelbuilder.error(nvisibility, "Error: `private` is the only legal visibility for properties in a private class.")
			else if mvisibility == private_visibility then
				assert nvisibility != null
				modelbuilder.advice(nvisibility, "useless-visibility", "Warning: `private` is superfluous since the only legal visibility for properties in a private class is private.")
			end
			mvisibility = private_visibility
		end
		return mvisibility
	end

	private fun set_doc(mpropdef: MPropDef, modelbuilder: ModelBuilder)
	do
		var ndoc = self.n_doc
		if ndoc != null then
			var mdoc = ndoc.to_mdoc
			mpropdef.mdoc = mdoc
			mdoc.original_mentity = mpropdef
		else if mpropdef.is_intro and mpropdef.mproperty.visibility >= protected_visibility and mpropdef.name != "new" then
			modelbuilder.advice(self, "missing-doc", "Documentation warning: Undocumented property `{mpropdef.mproperty}`")
		end

		var at_deprecated = get_single_annotation("deprecated", modelbuilder)
		if at_deprecated != null then
			if not mpropdef.is_intro then
				modelbuilder.error(self, "Error: method redefinition cannot be deprecated.")
			else
				var info = new MDeprecationInfo
				ndoc = at_deprecated.n_doc
				if ndoc != null then info.mdoc = ndoc.to_mdoc
				mpropdef.mproperty.deprecation = info
			end
		end
	end

	private fun check_redef_property_visibility(modelbuilder: ModelBuilder, nvisibility: nullable AVisibility, mprop: MProperty)
	do
		if nvisibility == null then return
		var mvisibility = nvisibility.mvisibility
		if mvisibility != mprop.visibility and mvisibility != public_visibility then
				modelbuilder.error(nvisibility, "Error: redefinition changed the visibility from `{mprop.visibility}` to `{mvisibility}`.")
		end
	end

	private fun check_redef_keyword(modelbuilder: ModelBuilder, mclassdef: MClassDef, kwredef: nullable Token, need_redef: Bool, mprop: MProperty): Bool
	do
		if mclassdef.mprop2npropdef.has_key(mprop) then
			modelbuilder.error(self, "Error: a property `{mprop}` is already defined in class `{mclassdef.mclass}` at line {mclassdef.mprop2npropdef[mprop].location.line_start}.")
			return false
		end
		if mprop isa MMethod and mprop.is_root_init then return true
		if kwredef == null then
			if need_redef then
				modelbuilder.error(self, "Redef Error: `{mclassdef.mclass}::{mprop.name}` is an inherited property. To redefine it, add the `redef` keyword.")
				return false
			end

			# Check for full-name conflicts in the package.
			# A public property should have a unique qualified name `package::class::prop`.
			if mprop.intro_mclassdef.mmodule.mgroup != null and mprop.visibility >= protected_visibility then
				var others = modelbuilder.model.get_mproperties_by_name(mprop.name)
				if others != null then for other in others do
					if other != mprop and other.intro_mclassdef.mmodule.mgroup != null and other.intro_mclassdef.mmodule.mgroup.mpackage == mprop.intro_mclassdef.mmodule.mgroup.mpackage and other.intro_mclassdef.mclass.name == mprop.intro_mclassdef.mclass.name and other.visibility >= protected_visibility then
						modelbuilder.advice(self, "full-name-conflict", "Warning: A property named `{other.full_name}` is already defined in module `{other.intro_mclassdef.mmodule}` for the class `{other.intro_mclassdef.mclass.name}`.")
						break
					end
				end
			end
		else
			if not need_redef then
				modelbuilder.error(self, "Error: no property `{mclassdef.mclass}::{mprop.name}` is inherited. Remove the `redef` keyword to define a new property.")
				return false
			end
		end
		return true
	end

	# Checks for useless type in redef signatures.
	private fun check_repeated_types(modelbuilder: ModelBuilder) do end
end
src/modelize/modelize_property.nit:579,1--680,3

nitc :: flow $ APropdef
redef class APropdef
	# The entry point of the whole flow analysis
	fun do_flow(toolcontext: ToolContext)
	do
		var v = new FlowVisitor(toolcontext)
		v.enter_visit(self)
	end


	# The starting flow
	var before_flow_context: nullable FlowContext is noautoinit

	# The ending flow
	var after_flow_context: nullable FlowContext is noautoinit

	redef fun accept_flow_visitor(v)
	do
		self.before_flow_context = v.current_flow_context
		super
		self.after_flow_context = v.current_flow_context
	end
end
src/semantize/flow.nit:256,1--277,3

nitc :: pretty $ APropdef
redef class APropdef
	redef fun accept_pretty_printer(v) do
		v.visit n_doc
		v.addt

		if not n_visibility isa nullable APublicVisibility then
			v.visit n_visibility
			v.adds
		end

		if n_kwredef != null then
			v.visit n_kwredef
			v.adds
		end
	end

	# Factorize annotations visit for all APropdef.
	#
	# Return true if annotations were inlined.
	fun visit_annotations(v: PrettyPrinterVisitor, n_annotations: nullable AAnnotations): Bool do
		var res = v.can_inline(n_annotations)
		if n_annotations != null then v.visit n_annotations
		return res
	end

	# Factorize block visit for APropdefs.
	#
	# Were annotations printed inline? If so, we need to print the block differently.
	fun visit_block(v: PrettyPrinterVisitor, n_block: nullable AExpr, annot_inline: Bool) do
		# var can_inline = v.can_inline(n_block)
		if n_block == null then return
		if n_annotations != null and not annot_inline then
			v.forcen
			v.addt
		end
		if v.inline_do then
			while not v.current_token isa TKwdo do v.skip
		end
		var token = v.current_token
		var do_inline = true
		loop
			if token isa TEol then
				v.skip
				if not v.can_inline(n_block) then
					v.forcen
					v.addt
					do_inline = false
				end
			end
			token = v.current_token
			if token isa TKwdo then break
		end
		if annot_inline and do_inline then v.adds
		v.consume "do"

		if v.can_inline(n_block) and do_inline then
			v.adds

			if n_block isa ABlockExpr then
				if n_block.n_expr.is_empty then
					v.visit n_block.n_kwend
				else
					v.visit n_block.n_expr.first
					v.current_token = n_block.n_kwend
					v.skip
				end
			else
				v.visit n_block
				if v.current_token isa TKwend then v.skip
			end
		else
			v.finish_line
			if was_inline then
				v.forcen
			else
				v.addn
			end
			v.indent += 1

			if n_block isa ABlockExpr then
				n_block.force_block = true
				v.visit n_block
				v.catch_up n_block.n_kwend
			else
				v.addt
				v.visit n_block
				v.forcen
			end

			v.indent -= 1
			v.addt
			if n_block isa ABlockExpr then
				v.visit n_block.n_kwend
			else
				v.add "end"
			end
		end
		v.finish_line
	end

	redef fun start_token do
		if n_doc == null then return super
		return n_doc.last_token.next_token
	end
end
src/pretty.nit:801,1--905,3

nitc :: local_var_init $ APropdef
redef class APropdef
	# Entry point of the whole local variable initialization verifier
	fun do_local_var_init(toolcontext: ToolContext)
	do
		var v = new LocalVarInitVisitor(toolcontext)
		v.enter_visit(self)
	end
end
src/semantize/local_var_init.nit:34,1--41,3

nitc :: typing $ APropdef
redef class APropdef
	# The entry point of the whole typing analysis
	fun do_typing(modelbuilder: ModelBuilder)
	do
	end

	# The variable associated to the receiver (if any)
	var selfvariable: nullable Variable
end
src/semantize/typing.nit:886,1--894,3

nitc :: naive_interpreter $ APropdef
redef class APropdef
	# Execute a `mpropdef` associated with the current node.
	private fun call(v: NaiveInterpreter, mpropdef: MMethodDef, args: Array[Instance]): nullable Instance
	do
		fatal(v, "NOT YET IMPLEMENTED method kind {class_name}. {mpropdef}")
		abort
	end
end
src/interpreter/naive_interpreter.nit:889,1--896,3

nitc :: ssa $ APropdef
redef class APropdef
	# The variables contained in the body on this propdef
	var variables: HashSet[Variable] = new HashSet[Variable] is lazy

	# The first basic block of the code
	var basic_block: nullable BasicBlock

	# If true, the basic blocks where generated
	var is_generated: Bool = false

	# Generate all basic blocks for this code
	fun generate_basic_blocks(ssa: SSA) is abstract

	# Contain all AST-parts related to object mechanisms the propdef has:
	# instantiation, method dispatch, attribute access, subtyping-test
	var object_sites: Array[AExpr] = new Array[AExpr]

	# The return variable of the propdef
	# Create an empty variable for the return of the method
	# and treat returns like variable assignments
	var returnvar: Variable = new Variable("returnvar")

	# Compute the three steps of SSA-algorithm
	# `ssa` A new instance of SSA class initialized with `self`
	fun compute_ssa(ssa: SSA)
	do
		if is_generated then return

		# The first step is to generate the basic blocks
		generate_basic_blocks(ssa)

		# The propdef has no body (abstract)
		if not is_generated then return

		# Once basic blocks were generated, compute SSA algorithm
		compute_phi(ssa)
		rename_variables(ssa)
		ssa_destruction(ssa)
	end

	# Compute the first phase of SSA algorithm: placing phi-functions
	fun compute_phi(ssa: SSA)
	do
		var root_block = basic_block.as(not null)

		# Compute the iterated dominance frontier of the graph of basic blocks
		root_block.compute_df

		# Places where a phi-function is added per variable
		var phi_blocks = new HashMap[Variable, Array[BasicBlock]]

		# For each variables in the propdef
		for v in variables do
			var phi_variables = new Array[BasicBlock]

			var read_blocks = new Array[BasicBlock]
			read_blocks.add_all(v.read_blocks)
			read_blocks.add_all(v.assignment_blocks)

			# While we have not treated each part accessing `v`
			while not read_blocks.is_empty do
				# Remove a block from the array
				var block = read_blocks.shift

				# For each block in the dominance frontier of `block`
				for df in block.dominance_frontier do
					# If we have not yet put a phi-function at the beginning of this block
					if not phi_variables.has(df) then
						phi_variables.add(df)

						# Create a new phi-function and set its dependences
						var phi = new PhiFunction("phi", df)
						phi.add_dependences(df, v)
						phi.block = df
						phi.original_variable = phi
						phi.declared_type = v.declared_type

						# Indicate this phi-function is assigned in this block
						phi.assignment_blocks.add(block)
						ssa.phi_functions.add(phi)

						# Add a phi-function at the beginning of df for variable v
						df.phi_functions.add(phi)

						if not v.read_blocks.has(df) or not v.assignment_blocks.has(df) then read_blocks.add(df)
					end
				end
			end

			# Add `phi-variables` to the global map
			phi_blocks[v] = phi_variables
		end
	end

	# Compute the second phase of SSA algorithm: renaming variables
	# NOTE: `compute_phi` must has been called before
	fun rename_variables(ssa: SSA)
	do
		# A counter for each variable
		# The key is the variable, the value the number of assignment into the variable
		var counter = new HashMap[Variable, Int]

		for v in variables do
			counter[v] = 0
			v.stack.push(v)
		end

		for phi in ssa.phi_functions do counter[phi] = 0

		# Launch the recursive renaming from the root block
		rename(basic_block.as(not null), counter, ssa)
	end

	# Recursively rename each variable from `block`
	# *`block` The starting basic block
	# *`counter` The key is the variable, the value the number of assignment into the variable
	fun rename(block: BasicBlock, counter: HashMap[Variable, Int], ssa: SSA)
	do
		if block.is_renaming then return

		block.is_renaming = true

		# For each phi-function of this block
		for phi in block.phi_functions do
			generate_name(phi, counter, block.first, ssa)

			# Replace the phi into the block
			block.phi_functions[block.phi_functions.index_of(phi)] = phi.original_variable.stack.last.as(PhiFunction)
		end

		# For each variable read in `block`
		for vread in block.read_sites do
			# Replace the old variable in AST
			vread.variable = vread.variable.original_variable.stack.last
		end

		# For each variable write
		for vwrite in block.write_sites do
			generate_name(vwrite.variable.as(not null), counter, vwrite, ssa)

			var new_version = vwrite.variable.original_variable.stack.last

			# Set dependence of the new variable
			if vwrite isa AVarReassignExpr then
				new_version.dep_exprs.add(vwrite.n_value)
			else if vwrite isa AVarAssignExpr then
				new_version.dep_exprs.add(vwrite.n_value)
			end

			# Replace the old variable by the last created
			vwrite.variable = new_version
		end

		# Rename occurrence of old names in phi-function
		for successor in block.dominance_frontier do
			for sphi in successor.phi_functions do
				# Go over the couples in the phi dependences to rename variables
				for couple in sphi.dependences do
					if couple.second == block then
						# Rename this variable
						couple.first = couple.first.original_variable.stack.last
					end
				end
			end
		end

		# Recurse in successor blocks
		for successor in block.successors do
			rename(successor, counter, ssa)
		end

		# Pop old names off the stack for each phi-function
		for phi in block.phi_functions do
			if not phi.stack.is_empty then phi.stack.pop
		end
	end

	# Generate a new version of the variable `v` and return it
	# *`v` The variable for which we generate a name
	# *`counter` The key is the variable, the value the number of assignment into the variable
	# *`expr` The AST node in which the assignment of v is made
	# *`ssa` The instance of SSA
	fun generate_name(v: Variable, counter: HashMap[Variable, Int], expr: ANode, ssa: SSA): Variable
	do
		var original_variable = v.original_variable.as(not null)

		var i = counter[original_variable]

		var new_version: Variable

		# Create a new version of Variable
		if original_variable isa PhiFunction then
			var block = original_variable.block
			new_version = new PhiFunction(original_variable.name + i.to_s, block)
			new_version.dependences.add_all(original_variable.dependences)
			ssa.phi_functions.add(new_version)
		else
			new_version = new Variable(original_variable.name + i.to_s)
			new_version.declared_type = expr.as(AVarFormExpr).variable.declared_type
			variables.add(new_version)
		end

		# Recopy the fields into the new version
		new_version.location = expr.location
		new_version.original_variable = original_variable

		# Push a new version on the stack
		original_variable.stack.add(new_version)
		counter[v] = i + 1

		return new_version
	end

	# Transform SSA-representation into an executable code (delete phi-functions)
	# `ssa` Current instance of SSA
	fun ssa_destruction(ssa: SSA)
	do
		var builder = new ASTBuilder(mpropdef.mclassdef.mmodule, mpropdef.mclassdef.bound_mtype)

		# Iterate over all phi-functions
		for phi in ssa.phi_functions do
			for dep in phi.dependences do
				# dep.second is the block where we need to create a varassign
				var var_read = builder.make_var_read(dep.first, dep.first.declared_type.as(not null))
				var nvar = builder.make_var_assign(dep.first, var_read)

				var block = dep.second.last.parent

				# This variable read must be add to a ABlockExpr
				if block isa ABlockExpr then
					block.add(nvar)
				end

				propagate_dependences(phi, phi.block)
				ssa.propdef.variables.add(dep.first)
			end
		end
	end

	# Propagate the dependences of the phi-functions into following variables
	# `phi` The PhiFunction
	# `block` Current block where we propagate dependences
	fun propagate_dependences(phi: PhiFunction, block: BasicBlock)
	do
		# Treat each block once
		if block.treated then return

		# For each variable access site in the block
		for site in block.variables_sites do
			if site isa AVarExpr then
				# Propagate the dependences of the phi-function in variables after the phi
				for dep in phi.dependences do
					for expr in dep.first.dep_exprs do
						if site.variable.dep_exprs.has(expr) then break

						if dep.first.original_variable == site.variable.original_variable then
							site.variable.dep_exprs.add(expr)
						end
					end
				end
			else
				# The site is a variable write, we stop the propagation
				return
			end
		end

		block.treated = true

		# If we do not meet a variable write, continue the propagation
		for b in block.successors do propagate_dependences(phi, b)
	end
end
src/ssa.nit:198,1--469,3

nitc :: variables_numbering $ APropdef
redef class APropdef
	# Indicite if this propdef was compile
	var is_compiled: Bool = false

	# Indicate if the variables numbering has been done
	private var is_numbering: Bool = false

	# The size of the environment to create to call this method
	private var environment_size: Int = 0

	# Compile this propdef
	# *`vm` The running instance of `VirtualMachine`
	fun compile(vm: VirtualMachine)
	do
		# Number the variables
		if not is_numbering then numbering_variables(vm)

		is_compiled = true
	end

	# Numbering the variable inside the propdef
	fun numbering_variables(vm: VirtualMachine) is abstract
end
src/vm/variables_numbering.nit:95,1--117,3

nitc :: contracts $ APropdef
redef class APropdef
	redef fun check_callsite(v)
	do
		v.visited_propdef = self
	end
end
src/contracts.nit:699,1--704,3

nitc :: abstract_compiler $ APropdef
redef class APropdef
	fun compile_to_c(v: AbstractCompilerVisitor, mpropdef: MMethodDef, arguments: Array[RuntimeVariable])
	do
		v.add("PRINT_ERROR(\"NOT YET IMPLEMENTED {class_name} {mpropdef} at {location.to_s}\\n\");")
		debug("Not yet implemented")
	end

	fun can_inline: Bool do return true
end
src/compiler/abstract_compiler.nit:2614,1--2622,3

nitc :: compilation $ APropdef
redef class APropdef

	redef fun compile(vm)
	do
		super

		# A new instance of SSA to analyze the self propdef
		var ssa = new SSA(self)

		# Generate basic_blocks and compute SSA-algorithm for this propdef
		compute_ssa(ssa)
	end

	# Redef to add the same position to a new version of a Variable than the original variable
	redef fun generate_name(v, counter, expr, ssa)
	do
		var new_version = super

		# All versions of a variable have the same position in the environment
		new_version.position = v.original_variable.position

		return new_version
	end
end
src/vm/compilation.nit:37,1--60,3

nitc :: java_compiler $ APropdef
redef class APropdef

	# Compile that property definition to java code
	fun compile_to_java(v: JavaCompilerVisitor, mpropdef: MMethodDef, arguments: Array[RuntimeVariable]) do
		v.info("NOT YET IMPLEMENTED {class_name}::compile_to_java")
	end
end
src/compiler/java_compiler.nit:1495,1--1501,3

nitc :: htmlight $ APropdef
redef class APropdef
	redef fun make_tag(v)
	do
		var res = new HTMLTag("span")
		res.add_class("nc_pdef")
		var mpd
		mpd = mpropdef
		if mpd != null then
			#res.add(tag(mpd))
			res.attr("id", mpd.to_s)
		end
		if self isa AAttrPropdef then
			mpd = mreadpropdef
			if mpd != null then res.add(tag(mpd))
			mpd = mwritepropdef
			if mpd != null then res.add(tag(mpd))
		end
		return res
	end

	private fun tag(mpd: MPropDef): HTMLTag
	do
		var a = new HTMLTag("a")
		a.attr("id", mpd.to_s)
		return a
	end
end
src/htmlight.nit:779,1--805,3