Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
Dwoo
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Common
Dwoo
Commits
1933f55c
Commit
1933f55c
authored
Aug 10, 2013
by
Thomas Bachem
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed compiler to work with modifiers on method calls in named parameters
Original issue:
http://bugs.dwoo.org/dwoo/bugs/issue/88
parent
e3fa9c52
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
Compiler.php
lib/Dwoo/Compiler.php
+7
-5
No files found.
lib/Dwoo/Compiler.php
View file @
1933f55c
...
...
@@ -1527,11 +1527,11 @@ class Dwoo_Compiler implements Dwoo_ICompiler
// parse modifier on funcs or vars
$srcPointer
=
$pointer
;
if
(
is_array
(
$parsingParams
))
{
$tmp
=
$this
->
replaceModifiers
(
array
(
null
,
null
,
$out
[
count
(
$out
)
-
1
][
0
],
$match
[
0
]),
'var'
,
$pointer
);
$tmp
=
$this
->
replaceModifiers
(
array
(
null
,
null
,
$out
[
count
(
$out
)
-
1
][
0
],
$match
[
0
]),
$curBlock
,
$pointer
);
$out
[
count
(
$out
)
-
1
][
0
]
=
$tmp
;
$out
[
count
(
$out
)
-
1
][
1
]
.=
substr
(
$substr
,
$srcPointer
,
$srcPointer
-
$pointer
);
}
else
{
$out
=
$this
->
replaceModifiers
(
array
(
null
,
null
,
$out
,
$match
[
0
]),
'var'
,
$pointer
);
$out
=
$this
->
replaceModifiers
(
array
(
null
,
null
,
$out
,
$match
[
0
]),
$curBlock
,
$pointer
);
}
}
...
...
@@ -2751,9 +2751,9 @@ class Dwoo_Compiler implements Dwoo_ICompiler
$pluginType
=
$this
->
getPluginType
(
$func
);
if
(
$state
&
2
)
{
array_unshift
(
$params
,
array
(
'value'
,
array
(
$output
,
$output
)));
array_unshift
(
$params
,
array
(
'value'
,
is_array
(
$output
)
?
$output
:
array
(
$output
,
$output
)));
}
else
{
array_unshift
(
$params
,
array
(
$output
,
$output
));
array_unshift
(
$params
,
is_array
(
$output
)
?
$output
:
array
(
$output
,
$output
));
}
if
(
$pluginType
&
Dwoo_Core
::
NATIVE_PLUGIN
)
{
...
...
@@ -2881,7 +2881,9 @@ class Dwoo_Compiler implements Dwoo_ICompiler
}
}
if
(
$curBlock
===
'var'
||
$m
[
1
]
===
null
)
{
if
(
$curBlock
===
'namedparam'
)
{
return
array
(
$output
,
$output
);
}
elseif
(
$curBlock
===
'var'
||
$m
[
1
]
===
null
)
{
return
$output
;
}
elseif
(
$curBlock
===
'string'
||
$curBlock
===
'root'
)
{
return
$m
[
1
]
.
'.'
.
$output
.
'.'
.
$m
[
1
]
.
(
isset
(
$add
)
?
$add
:
null
);
...
...
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