suppress Octal literals are not available when targeting ECMAScript 5 and higher.

This commit is contained in:
vvakame 2015-04-29 11:15:25 +09:00
parent 7dea7494db
commit 7faade2b23
5 changed files with 9 additions and 9 deletions

View File

@ -50,7 +50,7 @@ function FSTest(): void {
FS.symlink('file', 'link');
FS.writeFile('forbidden', 'can\'t touch this');
FS.chmod('forbidden', 0000);
FS.chmod('forbidden', parseInt("0000", 8));
FS.writeFile('file', 'foobar');
FS.truncate('file', 3);

View File

@ -18,6 +18,6 @@ gulp.task("concat:newLine", () => {
gulp.task("concat:vinyl", () => {
gulp.src(["file*.txt"])
.pipe(concat({ path: "file.txt", stat: { mode: 0666 } }))
.pipe(concat({ path: "file.txt", stat: { mode: parseInt("0666", 8) } }))
.pipe(gulp.dest("build"));
});

View File

@ -282,7 +282,7 @@ picker.set('disable', undefined);
picker.set('select', [2013, 3, 20]);
// Using JavaScript Date objects.
picker.set('select', new Date(2013,03,20));
picker.set('select', new Date(2013, 3, 20));
// Using positive integers as UNIX timestamps.
picker.set('select', 1365961912346);
@ -417,4 +417,4 @@ picker.on('open', function () {
picker.trigger('open');
picker.$node;
picker.$root;
picker.$root;

View File

@ -50,7 +50,7 @@ function d() {
function e() {
mock({
'some/dir': mock.directory({
mode: 0755,
mode: parseInt("0755", 8),
items: {
file1: 'file one content',
file2: new Buffer([8, 6, 7, 5, 3, 0, 9])

View File

@ -227,7 +227,7 @@ var dataWrap = function(fn:any) {
};
var realMode = function(n:any) {
return n & 07777;
return n & parseInt("07777", 8);
};
describe('dest stream', function() {
@ -370,7 +370,7 @@ describe('dest stream', function() {
var expectedContents = fs.readFileSync(inputPath);
var expectedCwd = __dirname;
var expectedBase = path.join(__dirname, "./out-fixtures");
var expectedMode = 0655;
var expectedMode = parseInt("0655", 8);
var expectedFile = new File({
base: inputBase,
@ -410,7 +410,7 @@ describe('dest stream', function() {
var expectedContents = fs.readFileSync(inputPath);
var expectedCwd = __dirname;
var expectedBase = path.join(__dirname, "./out-fixtures");
var expectedMode = 0655;
var expectedMode = parseInt("0655", 8);
var contentStream = through.obj();
var expectedFile = new File({
@ -454,7 +454,7 @@ describe('dest stream', function() {
var expectedPath = path.join(__dirname, "./out-fixtures/test");
var expectedCwd = __dirname;
var expectedBase = path.join(__dirname, "./out-fixtures");
var expectedMode = 0655;
var expectedMode = parseInt("0655", 8);
var expectedFile = new File({
base: inputBase,