summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2010-06-19 07:15:36 +0000
committerbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2010-06-19 07:15:36 +0000
commit7966471a183959f711b37f265d219071fabced8d (patch)
tree268cebfefda6cce93792b4bf9bcf700d515cd482
parentc450b0ca4bae90a739631be170cbbbc3f87e4dad (diff)
downloadgcc-7966471a183959f711b37f265d219071fabced8d.tar.gz
2010-06-19 Basile Starynkevitch <basile@starynkevitch.net>
* melt/warmelt-first.melt: Fixed typo in is_non_empty_list. * melt/warmelt-normatch.melt: Added debug_msg... * testsuite/gcc/melt/tmatch-6.melt: commented some code. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@161022 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog.MELT5
-rw-r--r--gcc/melt/warmelt-first.melt2
-rw-r--r--gcc/melt/warmelt-normatch.melt6
-rw-r--r--gcc/testsuite/melt/tmatch-6.melt4
4 files changed, 13 insertions, 4 deletions
diff --git a/gcc/ChangeLog.MELT b/gcc/ChangeLog.MELT
index e26a797bb96..53d93eeff70 100644
--- a/gcc/ChangeLog.MELT
+++ b/gcc/ChangeLog.MELT
@@ -1,4 +1,9 @@
+2010-06-19 Basile Starynkevitch <basile@starynkevitch.net>
+ * melt/warmelt-first.melt: Fixed typo in is_non_empty_list.
+ * melt/warmelt-normatch.melt: Added debug_msg...
+ * testsuite/gcc/melt/tmatch-6.melt: commented some code.
+
2010-06-18 Basile Starynkevitch <basile@starynkevitch.net>
* melt/xtramelt-ana-base.melt: exporting gimple_cond_with_edges
diff --git a/gcc/melt/warmelt-first.melt b/gcc/melt/warmelt-first.melt
index a45d8fdfe3b..4998305d3a0 100644
--- a/gcc/melt/warmelt-first.melt
+++ b/gcc/melt/warmelt-first.melt
@@ -1344,7 +1344,7 @@ make a $CURAT string.}#
;; test if a list is non-empty
(defprimitive is_non_empty_list (li) :long
:doc #{Test if value $LI is a non-empty list.}#
- #{(melt_magic_discr((melt_ptr_t)($li)) == OBMAG_LIST && NULL == melt_list_first((melt_ptr_t)($li)))}#)
+ #{(melt_magic_discr((melt_ptr_t)($li)) == OBMAG_LIST && NULL != melt_list_first((melt_ptr_t)($li)))}#)
;; first pair of list
(defprimitive list_first (li) :value
:doc #{Safely retrieve the first pair of list value $LI, or null.}#
diff --git a/gcc/melt/warmelt-normatch.melt b/gcc/melt/warmelt-normatch.melt
index f5c38e5b7c7..180185b1a73 100644
--- a/gcc/melt/warmelt-normatch.melt
+++ b/gcc/melt/warmelt-normatch.melt
@@ -4963,16 +4963,20 @@ normalized expression.}#
((is_multiple msteps)
(void))
((is_non_empty_list msteps)
+ (debug_msg msteps "altmatch_handle_normalized_mdata msteps nonemptylist")
(let ( (firststep (list_first_element msteps))
)
(assert_msg "check firststep" (is_a firststep class_match_step))
;; the call to match_step_index will as a side effect change
;; msteps to a list!
+ (debug_msg msteps "altmatch_handle_normalized_mdata msteps before match_step_index")
(match_step_index firststep)
(setq msteps (unsafe_get_field :mdata_steps matdata))
+ (debug_msg msteps "altmatch_handle_normalized_mdata msteps after match_step_index")
))
(:else
- (setq msteps (make_multiple discr_multiple 0))))
+ (setq msteps (make_multiple discr_multiple 0))
+ (debug_msg msteps "altmatch_handle_normalized_mdata msteps emptytuple")))
(debug_msg msteps "altmatch_handle_normalized_mdata updated msteps")
(assert_msg "good tuple msteps" (is_multiple msteps))
(foreach_in_multiple
diff --git a/gcc/testsuite/melt/tmatch-6.melt b/gcc/testsuite/melt/tmatch-6.melt
index 1cdb728cacd..325c5d86be1 100644
--- a/gcc/testsuite/melt/tmatch-6.melt
+++ b/gcc/testsuite/melt/tmatch-6.melt
@@ -15,7 +15,7 @@
?(instance class_symbol :named_name
?synam)
synam)))
-
+#|
(debug_msg (testnameofsymbol 'asymbol) "testnameofsymbol asymbol")
(defun testnameofclassoffield (fld)
@@ -126,7 +126,7 @@
)
(?(instance class_located :loca_location ?fldloc)
(error_plain fldloc "expecting field in infix notation")))))
-
+|#