@volar/source-map 1.4.0-alpha.1 → 1.4.0-alpha.11

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.
Files changed (2) hide show
  1. package/out/index.js +4 -1
  2. package/package.json +2 -2
package/out/index.js CHANGED
@@ -1,3 +1,4 @@
1
+ "use strict";
1
2
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
2
3
  if (k2 === undefined) k2 = k;
3
4
  var desc = Object.getOwnPropertyDescriptor(m, k);
@@ -104,7 +105,9 @@ class SourceMap {
104
105
  if (baseOnRight) {
105
106
  offset += (mappedToRange[1] - mappedToRange[0]) - (mappedFromRange[1] - mappedFromRange[0]);
106
107
  }
107
- return offset;
108
+ if (offset >= mappedToRange[0] && offset <= mappedToRange[1]) {
109
+ return offset;
110
+ }
108
111
  }
109
112
  }
110
113
  binarySearchMemo(array, start) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@volar/source-map",
3
- "version": "1.4.0-alpha.1",
3
+ "version": "1.4.0-alpha.11",
4
4
  "main": "out/index.js",
5
5
  "license": "MIT",
6
6
  "files": [
@@ -15,5 +15,5 @@
15
15
  "dependencies": {
16
16
  "muggle-string": "^0.2.2"
17
17
  },
18
- "gitHead": "41ea915b137aea284e2bf5edd98a788ce21b779c"
18
+ "gitHead": "56ab336278ed7f06851c3dfe1bbcd5b9a3112846"
19
19
  }