1cb93a386Sopenharmony_ci// Copyright 2019 Google LLC. 2cb93a386Sopenharmony_ci// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. 3cb93a386Sopenharmony_ci#ifndef stringview_DEFINED 4cb93a386Sopenharmony_ci#define stringview_DEFINED 5cb93a386Sopenharmony_ci 6cb93a386Sopenharmony_ci#include <cstddef> 7cb93a386Sopenharmony_ci 8cb93a386Sopenharmony_cinamespace SkPlainTextEditor { 9cb93a386Sopenharmony_ci 10cb93a386Sopenharmony_citemplate <typename T> 11cb93a386Sopenharmony_cistruct Span { 12cb93a386Sopenharmony_ci T* data; 13cb93a386Sopenharmony_ci std::size_t size; 14cb93a386Sopenharmony_ci}; 15cb93a386Sopenharmony_ci 16cb93a386Sopenharmony_ciusing StringView = Span<const char>; 17cb93a386Sopenharmony_ci 18cb93a386Sopenharmony_ci} // namespace SkPlainTextEditor 19cb93a386Sopenharmony_ci#endif // stringview_DEFINED 20