Skip to content

Commit

Permalink
Adding of indexedFileAnchor
Browse files Browse the repository at this point in the history
  • Loading branch information
uNouss committed Aug 16, 2023
1 parent 390dce6 commit 9bc3f87
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
"
I hold the position in the source file
"
Class {
#name : #FamixFortran03IndexedFileAnchor,
#superclass : #FamixFortran03SourceAnchor,
#traits : 'FamixTFileNavigation',
#classTraits : 'FamixTFileNavigation classTrait',
#category : #'Famix-Fortran03-Entities-Entities'
}

{ #category : #meta }
FamixFortran03IndexedFileAnchor class >> annotation [

<FMClass: #IndexedFileAnchor super: #FamixFortran03SourceAnchor>
<package: #'Famix-Fortran03-Entities'>
<generated>
^ self
]
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,13 @@ FamixFortran03TEntityCreator >> newFunctionNamed: aName [
^ self add: (FamixFortran03Function named: aName)
]

{ #category : #'entity creation' }
FamixFortran03TEntityCreator >> newIndexedFileAnchor [

<generated>
^ self add: FamixFortran03IndexedFileAnchor new
]

{ #category : #'entity creation' }
FamixFortran03TEntityCreator >> newModule [

Expand Down
11 changes: 10 additions & 1 deletion src/Famix-Fortran03-Generator/FamixFortran03Generator.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ Class {
'subroutine',
'type',
'use',
'variable'
'variable',
'indexedFileAnchor'
],
#category : #'Famix-Fortran03-Generator'
}
Expand Down Expand Up @@ -51,6 +52,11 @@ FamixFortran03Generator >> defineClasses [
comment:
'Im a function. You can use me in a expression and I have a declaredType: r = fct(p1,...,pN)'.

indexedFileAnchor := builder
newClassNamed: #IndexedFileAnchor
comment:
'I hold the position in the source file'.

module := builder
newClassNamed: #Module
comment:
Expand Down Expand Up @@ -110,6 +116,9 @@ FamixFortran03Generator >> defineHierarchy [
function --|> procedure.
function --|> #TFunction.

indexedFileAnchor --|> sourceAnchor.
indexedFileAnchor --|> #TFileNavigation.

module --|> programUnit.

procedure --|> programUnit.
Expand Down

0 comments on commit 9bc3f87

Please sign in to comment.