Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
preprocessor
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
7
Issues
7
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dynare
preprocessor
Commits
5200cf6e
Verified
Commit
5200cf6e
authored
Jan 21, 2020
by
Houtan Bastani
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
macro processor: declare function const
(cherry picked from commit
3c546ddb
)
parent
bbc621ca
Pipeline
#2940
passed with stages
in 3 minutes and 30 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
src/macro/Environment.cc
src/macro/Environment.cc
+1
-1
src/macro/Environment.hh
src/macro/Environment.hh
+1
-1
No files found.
src/macro/Environment.cc
View file @
5200cf6e
...
...
@@ -67,7 +67,7 @@ Environment::getFunction(const string &name) const
}
codes
::
BaseType
Environment
::
getType
(
const
string
&
name
)
Environment
::
getType
(
const
string
&
name
)
const
{
return
getVariable
(
name
)
->
eval
()
->
getType
();
}
...
...
src/macro/Environment.hh
View file @
5200cf6e
...
...
@@ -40,7 +40,7 @@ namespace macro
void
define
(
FunctionPtr
func
,
ExpressionPtr
value
);
ExpressionPtr
getVariable
(
const
string
&
name
)
const
;
tuple
<
FunctionPtr
,
ExpressionPtr
>
getFunction
(
const
string
&
name
)
const
;
codes
::
BaseType
getType
(
const
string
&
name
);
codes
::
BaseType
getType
(
const
string
&
name
)
const
;
bool
isVariableDefined
(
const
string
&
name
)
const
noexcept
;
bool
isFunctionDefined
(
const
string
&
name
)
const
noexcept
;
inline
bool
isSymbolDefined
(
const
string
&
name
)
const
noexcept
{
return
isVariableDefined
(
name
)
||
isFunctionDefined
(
name
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment