Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cduce
cduce
Commits
5be34b0e
Commit
5be34b0e
authored
Oct 05, 2007
by
Pietro Abate
Browse files
[r2006-03-17 14:19:53 by afrisch] Deal with 'namespace on'
Original author: afrisch Date: 2006-03-17 14:19:53+00:00
parent
c44f007c
Changes
1
Hide whitespace changes
Inline
Side-by-side
schema/schema_common.ml
View file @
5be34b0e
...
...
@@ -131,7 +131,8 @@ let stream_of_value v =
let
f
_
=
(* lazy visit of a tree of CDuce XML values, stack keeps track of
what has still to be visited *)
match
!
stack
with
|
(
Fully
((
Value
.
Xml
(
Value
.
Atom
atom
,
attrs
,
_
))
as
v
))
::
tl
->
|
(
Fully
((
Value
.
Xml
(
Value
.
Atom
atom
,
attrs
,
_
))
|
(
Value
.
XmlNs
(
Value
.
Atom
atom
,
attrs
,
_
,
_
))
as
v
))
::
tl
->
stack
:=
(
Half
v
)
::
tl
;
let
children
=
ref
[]
in
(* TODO inefficient *)
let
push
v
s
=
(
s
:=
v
::
!
s
)
in
...
...
@@ -139,7 +140,7 @@ let stream_of_value v =
(
fun
pcdata
->
push
(
Other
pcdata
)
children
)
(
fun
v
->
match
v
with
|
(
Value
.
Xml
(
_
,
_
,
_
)
)
as
v
->
push
(
Fully
v
)
children
|
(
Value
.
Xml
_
|
Value
.
XmlNs
_
)
as
v
->
push
(
Fully
v
)
children
|
v
->
raise
(
Invalid_argument
"Schema_events.stream_of_value"
))
v
;
stack
:=
(
List
.
rev
!
children
)
@
!
stack
;
...
...
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