I revived a two-year old project today as the client needs more features. I discovered to my horror that something has apparently changed in OpenDX since last I ran this net. I've attached a simple test net if someone else can try and verify the error. I don't see anything in the mail archives that directly indicates anyone has mucked with invalid positions lately.
In summary: I create a component through various operations that will become the "invalid positions" component, protecting it by giving it a non-reserved name, like "invalid_poz". Then, when I'm done creating it, I Rename("invalid_poz","invalid positions"). This used to work just fine. But now, invariably, the "invalid positions" all become = 01 after Rename, even though the array is demonstrably NOT all = 01 before the Rename. There is no other "invalid..." component(s) in the field. Replace(field, field, "invalid_poz", "invalid positions") does the same thing, i.e., corrupts the input array into an all 01 array. Sigh. This is on Mac OSX, with OpenDX 4.3, freshly installed off the new CD today. The last time I ran this net was on an SGI, probably OpenDX 4.1. I may also have run it on Windoze, also 4.1 or thereabouts. It worked back then.
Can someone please try this on another system (esp. an older openDX, but also on 4.3) to see if they get the correct behavior? The correct behavior in this test net is that "invalid positions" would be 00 00 00 00 00 01 01 01 01 01. Thanks.
Here it is:
//
// time: Sat Aug 16 21:47:38 2003
//
// version: 3.2.0 (format), 4.3.0 (DX)
//
//
// MODULE main
// workspace: width = 228, height = 378
// layout: snap = 0, width = 50, height = 50, align = NN
//
macro main(
) -> (
) {
//
// node Construct[24]: x = 0, y = 0, inputs = 4, label = Construct
// input[2]: defaulting = 0, visible = 1, type = 16777224, value = {[1]}
// input[3]: defaulting = 0, visible = 1, type = 1, value = 10
// input[4]: defaulting = 0, visible = 1, type = 16777245, value = {0,0,0,0,0,1,1,1,1,1}
//
main_Construct_24_out_1 =
Construct(
main_Construct_24_in_1,
main_Construct_24_in_2,
main_Construct_24_in_3,
main_Construct_24_in_4
) [instance: 24, cache: 1];
//
// node Remove[27]: x = 33, y = 76, inputs = 2, label = Remove
// input[2]: defaulting = 0, visible = 1, type = 32, value = "connections"
//
main_Remove_27_out_1 =
Remove(
main_Construct_24_out_1,
main_Remove_27_in_2
) [instance: 27, cache: 1];
//
// node Compute[419]: x = 30, y = 153, inputs = 2, label = Compute
// input[1]: defaulting = 0, visible = 0, type = 32, value = "byte($0)"
// expression: value = byte(a)
// name[2]: value = a
//
main_Compute_419_out_1 =
Compute(
main_Compute_419_in_1,
main_Remove_27_out_1
) [instance: 419, cache: 1];
//
// node Rename[74]: x = 2, y = 241, inputs = 3, label = Rename
// input[2]: defaulting = 0, visible = 1, type = 32, value = "data"
// input[3]: defaulting = 0, visible = 1, type = 32, value = "invalid positions"
//
main_Rename_74_out_1 =
Rename(
main_Compute_419_out_1,
main_Rename_74_in_2,
main_Rename_74_in_3
) [instance: 74, cache: 1];
//
// node Print[5]: x = 26, y = 316, inputs = 3, label = Print
// input[2]: defaulting = 0, visible = 1, type = 32, value = "rd"
//
Print(
main_Rename_74_out_1,
main_Print_5_in_2,
main_Print_5_in_3
) [instance: 5, cache: 1];
//
// node Replace[81]: x = 120, y = 240, inputs = 4, label = Replace
// input[4]: defaulting = 0, visible = 1, type = 32, value = "invalid positions"
//
main_Replace_81_out_1 =
Replace(
main_Compute_419_out_1,
main_Compute_419_out_1,
main_Replace_81_in_3,
main_Replace_81_in_4
) [instance: 81, cache: 1];
//
// node Print[6]: x = 156, y = 313, inputs = 3, label = Print
// input[2]: defaulting = 0, visible = 1, type = 32, value = "rd"
//
Print(
main_Replace_81_out_1,
main_Print_6_in_2,
main_Print_6_in_3
) [instance: 6, cache: 1];
// network: end of macro body
}
main_Construct_24_in_1 = NULL;
main_Construct_24_in_2 = {[1]};
main_Construct_24_in_3 = 10;
main_Construct_24_in_4 = {0,0,0,0,0,1,1,1,1,1};
main_Construct_24_out_1 = NULL;
main_Remove_27_in_2 = "connections";
main_Remove_27_out_1 = NULL;
main_Compute_419_in_1 = "byte($0)";
main_Compute_419_out_1 = NULL;
main_Rename_74_in_2 = "data";
main_Rename_74_in_3 = "invalid positions";
main_Rename_74_out_1 = NULL;
main_Print_5_in_2 = "rd";
main_Print_5_in_3 = NULL;
main_Replace_81_in_3 = NULL;
main_Replace_81_in_4 = "invalid positions";
main_Replace_81_out_1 = NULL;
main_Print_6_in_2 = "rd";
main_Print_6_in_3 = NULL;
Executive("product version 4 3 0");
$sync
main();
____________________________
Chris Pelkie
Vice President
Conceptual Reality Presentations, Inc.
30 West Meadow Drive
Ithaca, NY 14850
