svf-lib 1.0.820 → 1.0.824

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -86,7 +86,7 @@ public:
86
86
 
87
87
  /// Copy Constructor
88
88
  LocationSet(const LocationSet& ls)
89
- : fldIdx(ls.fldIdx)
89
+ : fldIdx(ls.fldIdx), offsetValues(ls.getOffsetValueVec())
90
90
  {
91
91
  }
92
92
 
@@ -437,12 +437,20 @@ public:
437
437
  assert(isVariantFieldGep()==false && "Can't retrieve the LocationSet if using a variable field index (pointer arithmetic) for struct field access ");
438
438
  return ls;
439
439
  }
440
-
440
+ inline const LocationSet::OffsetValueVec& getOffsetValueVec() const
441
+ {
442
+ return getLocationSet().getOffsetValueVec();
443
+ }
444
+ /// Return TRUE if this is a constant location set.
445
+ inline bool isConstantOffset() const{
446
+ return getLocationSet().isConstantOffset();
447
+ }
448
+ /// Return accumulated constant offset (when accessing array or struct) if this offset is a constant.
441
449
  inline s64_t accumulateConstantOffset() const
442
450
  {
443
- return ls.accumulateConstantOffset();
451
+ return getLocationSet().accumulateConstantOffset();
444
452
  }
445
- /// offset of the gep statement
453
+ /// Field index of the gep statement if it access the field of a struct
446
454
  inline s64_t getConstantFieldIdx() const
447
455
  {
448
456
  return getLocationSet().accumulateConstantFieldIdx();
Binary file
@@ -86,7 +86,7 @@ public:
86
86
 
87
87
  /// Copy Constructor
88
88
  LocationSet(const LocationSet& ls)
89
- : fldIdx(ls.fldIdx)
89
+ : fldIdx(ls.fldIdx), offsetValues(ls.getOffsetValueVec())
90
90
  {
91
91
  }
92
92
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "svf-lib",
3
- "version": "1.0.820",
3
+ "version": "1.0.824",
4
4
  "description": "SVF's npm support",
5
5
  "main": "index.js",
6
6
  "scripts": {