Declarative state space reduction in a transactional messaging language
First Claim
1. A computer-implemented method of processing a computer language, comprising:
- reading computer code comprising at least one variable and a code transaction;
detecting a statement within the code, wherein the statement specifies the code transaction and indicates that in a first logic path an exception occurred in the code transaction and in a second logic path an exception did not occur in the code transaction;
analyzing the code transaction according to each logic path and determining an assignment state of the at least one variable in the first and second logic paths;
merging the assignment state of the at least one variable as determined in the first logic path with the assignment state of the at least one variable as determined in the second logic path; and
determining whether a function is performed within the code with respect to the variable while the variable has a merged assignment state being an incorrect assignment state and, if so, declaring the function to be invalid.
2 Assignments
0 Petitions
Accused Products
Abstract
A XLANG/s compiler recognizes a statement in XLANG/s code to make an assumption as to the success or failure of a specified transaction. The assignment states of variables are tracked and changes to such states are recorded. While processing XLANG/s code, the compiler determines whether the assignment state of a particular correlation, operation or the like is correct for the transaction being performed. If not, the compiler may generate an error message. Moreover, by using declarative assumptions such as if(succeeded(T)) or if(!succeeded(T)), definite-assignment analysis of shared state variables may cross transactional boundaries.
-
Citations
50 Claims
-
1. A computer-implemented method of processing a computer language, comprising:
-
reading computer code comprising at least one variable and a code transaction;
detecting a statement within the code, wherein the statement specifies the code transaction and indicates that in a first logic path an exception occurred in the code transaction and in a second logic path an exception did not occur in the code transaction;
analyzing the code transaction according to each logic path and determining an assignment state of the at least one variable in the first and second logic paths;
merging the assignment state of the at least one variable as determined in the first logic path with the assignment state of the at least one variable as determined in the second logic path; and
determining whether a function is performed within the code with respect to the variable while the variable has a merged assignment state being an incorrect assignment state and, if so, declaring the function to be invalid. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20)
-
-
21. A method of compiling a XLANG/s program, comprising:
-
(a) reading XLANG/s code comprising at least one variable, a code transaction and at least one of an if(succeeded(n)) statement or an if(!succeeded(n)) statement;
(b) detecting, using a XLANG/s compiler, the if(succeeded(n)) or if(!succeeded(n)) statement, where n denotes the code transaction;
(c) assuming, if the if(succeeded(n)) statement was detected, that the code transaction executed without error or, if the if(!succeeded(n)) statement was detected, assuming that an error occurred with respect to the execution of the code transaction;
(d) determining an assignment state of the at least one variable according to the assumption of step (c); and
(e) determining whether a pending operation can be completed subject to the assignment state of the at least one variable determined in step (d) and, if the pending operation cannot be completed, declaring the pending operation to be invalid. - View Dependent Claims (22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35)
-
-
36. A computer-readable medium having computer-executable instructions for performing a method of compiling a XLANG/s program, the method comprising:
-
(a) reading XLANG/s code comprising at least one variable, a code transaction and at least one of an if(succeeded(n)) statement or an if(!succeeded(n)) statement;
(b) detecting, using a XLANG/s compiler, the if(succeeded(n)) or if(!succeeded(n)) statement, where n denotes the code transaction;
(c) assuming, if the if(succeeded(n)) statement was detected, that the code transaction executed without error or, if the if(!succeeded(n)) statement was detected, assuming that an error occurred with respect to the execution of the code transaction;
(d) determining an assignment state of the at least one variable according to the assumption of step (c); and
(e) determining whether a pending operation can be completed subject to the assignment state of the at least one variable determined in step (d) and, if the pending operation cannot be completed, declaring the pending operation to be invalid. - View Dependent Claims (37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50)
-
Specification