dart-sdk/runtime/bin/file_win.h
Alexander Aprelev 48e5cba6b9 Reland "Enable long path on Windows"
This reverts commit f8fbefd951 in patchset 1 with fixes to the way how temporary strings are allocated and the way how prefixed string is returned in successive patchsets.

Fixes https://github.com/dart-lang/sdk/issues/42416

Change-Id: Idb801cb117fc2d84fad4c533f5239d8499afc943
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/164741
Commit-Queue: Alexander Aprelev <aam@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2020-10-02 00:54:46 +00:00

23 lines
674 B
C++

// Copyright (c) 2020, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
#ifndef RUNTIME_BIN_FILE_WIN_H_
#define RUNTIME_BIN_FILE_WIN_H_
#include "bin/file.h"
// The limit for a regular directory is 248.
// Reference: https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file#maximum-path-length-limitation
#define MAX_DIRECTORY_PATH (MAX_PATH - 12)
namespace dart {
namespace bin {
const char* PrefixLongDirectoryPath(const char* path);
} // namespace bin
} // namespace dart
#endif // RUNTIME_BIN_FILE_WIN_H_