Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
pike
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pikelang
pike
Commits
3fcd53eb
Commit
3fcd53eb
authored
25 years ago
by
Martin Stjernholm
Browse files
Options
Downloads
Patches
Plain Diff
Defeated type checks in the has_index()/has_value() tests. Fixed a
typo. Rev: src/testsuite.in:1.263
parent
aa148881
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/testsuite.in
+25
-25
25 additions, 25 deletions
src/testsuite.in
with
25 additions
and
25 deletions
src/testsuite.in
+
25
−
25
View file @
3fcd53eb
test_true([["$Id: testsuite.in,v 1.26
2
2000/01/2
0 23:12:01 noring
Exp $"]]);
test_true([["$Id: testsuite.in,v 1.26
3
2000/01/2
4 03:28:29 mast
Exp $"]]);
cond([[all_constants()->_verify_internals]],
cond([[all_constants()->_verify_internals]],
[[
[[
...
@@ -3726,33 +3726,33 @@ test_true(arrayp(rusage()))
...
@@ -3726,33 +3726,33 @@ test_true(arrayp(rusage()))
test_true(sizeof(rusage())>0)
test_true(sizeof(rusage())>0)
// - has_index
// - has_index
test_false([[ has_index(({}), 0) ]])
test_false([[ has_index(
[mixed]
({}), 0) ]])
test_false([[ has_index(({}), "foo") ]])
test_false([[ has_index(
[mixed]
({}), "foo") ]])
test_false([[ has_index(({ "a" }), -1) ]])
test_false([[ has_index(
[mixed]
({ "a" }), -1) ]])
test_false([[ has_index(({ "a" }), "a") ]])
test_false([[ has_index(
[mixed]
({ "a" }), "a") ]])
test_true([[ has_index(({ "a" }), 0) ]])
test_true([[ has_index(
[mixed]
({ "a" }), 0) ]])
test_false([[ has_index(({ "a" }), 1) ]])
test_false([[ has_index(
[mixed]
({ "a" }), 1) ]])
test_true([[ has_index(({ "a", "b" }), 1) ]])
test_true([[ has_index(
[mixed]
({ "a", "b" }), 1) ]])
test_false([[ has_index(([ "a":"A" ]), 4711) ]])
test_false([[ has_index(
[mixed]
([ "a":"A" ]), 4711) ]])
test_true([[ has_index(([ "a":"A" ]), "a") ]])
test_true([[ has_index(
[mixed]
([ "a":"A" ]), "a") ]])
test_false([[ has_index(([ "a":"A" ]), "A") ]])
test_false([[ has_index(
[mixed]
([ "a":"A" ]), "A") ]])
test_true([[ has_index(([ "a":"A", "b":"B", "c":"C" ]), "b") ]])
test_true([[ has_index(
[mixed]
([ "a":"A", "b":"B", "c":"C" ]), "b") ]])
test_false([[ has_index(([ "a":"A", "b":"B", "c":"C" ]), "B") ]])
test_false([[ has_index(
[mixed]
([ "a":"A", "b":"B", "c":"C" ]), "B") ]])
test_eval_error([[ has_index((class {})(), "foo") ]])
test_eval_error([[ has_index((class {})(), "foo") ]])
test_true([[has_index((class{array _indices(){return({"a","b"});}})(),"b")]])
test_true([[has_index((class{array _indices(){return({"a","b"});}})(),"b")]])
// - has_value
// - has_value
test_false([[ has_value(({}), 0) ]])
test_false([[ has_value(
[mixed]
({}), 0) ]])
test_false([[ has_value(({}), "foo") ]])
test_false([[ has_value(
[mixed]
({}), "foo") ]])
test_false([[ has_value(({ "a" }), -1) ]])
test_false([[ has_value(
[mixed]
({ "a" }), -1) ]])
test_true([[ has_value(({ "a" }), "a") ]])
test_true([[ has_value(
[mixed]
({ "a" }), "a") ]])
test_false([[ has_value(({ "a" }), 0) ]])
test_false([[ has_value(
[mixed]
({ "a" }), 0) ]])
test_true([[ has_value(({ "a", "b" }), "b") ]])
test_true([[ has_value(
[mixed]
({ "a", "b" }), "b") ]])
test_false([[ has_value(([ "a":"A" ]), 4711) ]])
test_false([[ has_value(
[mixed]
([ "a":"A" ]), 4711) ]])
test_true([[ has_value(([ "a":"A" ]), "A") ]])
test_true([[ has_value(
[mixed]
([ "a":"A" ]), "A") ]])
test_false([[ has_value(([ "a":"A" ]), "a") ]])
test_false([[ has_value(
[mixed]
([ "a":"A" ]), "a") ]])
test_true([[ has_value(([ "a":"A", "b":"B", "c":"C" ]), "B") ]])
test_true([[ has_value(
[mixed]
([ "a":"A", "b":"B", "c":"C" ]), "B") ]])
test_false([[ has_value(([ "a":"A", "b":"B", "c":"C" ]), "b") ]])
test_false([[ has_value(
[mixed]
([ "a":"A", "b":"B", "c":"C" ]), "b") ]])
test_eval_error([[ has_value((class {})(), "foo") ]])
test_eval_error([[ has_value((class {})(), "foo") ]])
test_true([[has_value((class{array _values(){return({"a","b"});}})(),"b")]])
test_true([[has_value((class{array _values(){return({"a","b"});}})(),"b")]])
...
@@ -3795,7 +3795,7 @@ test_do([[
...
@@ -3795,7 +3795,7 @@ test_do([[
{
{
m = _m;
m = _m;
}
}
}
}
;
mapping m = ([ ]);
mapping m = ([ ]);
C o = C(m);
C o = C(m);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment