Skip to content

Commit 0d5b3aa

Browse files
authored
Add Support for BitVector and BitMatrix Indexing
Fixes #707.
1 parent ab44000 commit 0d5b3aa

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

test/test_atoms.jl

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -520,6 +520,15 @@ function test_IndexAtom()
520520
y = [true, false, true]
521521
x = Variable(3)
522522
@test string(x[y]) == string([x[1], x[3]])
523+
target = """
524+
variables: x1, x2, x3
525+
minobjective: [1.0 * x1, 1.0 * x3]
526+
"""
527+
_test_atom(target) do context
528+
x = Variable(3)
529+
y = BitVector([true, false, true])
530+
return x[y]
531+
end
523532
return
524533
end
525534

0 commit comments

Comments
 (0)