Unexpected behavior when using algorithm::trim() to remove spaces
還沒有人認領這個 Issue。
評估
研究方向
從 algorithm::trim() 開始,使用 Android NDK 中的 Linux 交叉編譯器重現 boostorg/compute#817 中的逗號分隔範例。將其行為與 Windows 上的 MSVC 以及 macOS 上的 GCC/Clang 進行比較,以隔離平台特定的原因。當原因獲得解釋,且回報的輸出在沒有回歸的情況下得到修正時,即視為完成。
由索引模型根據 Issue 內容生成。
描述
The issue comes from boostorg/compute#817 where boost::trim() is invoked to sanitize OpenCL kernel arguments from preprocessor-generated strings. One of the failing cases taken directly from the boost compute repo is this:
two, pi // original string
[two, pi] // vector after split() using comma as delimiter
two // first element after trim()
p // second element after trim()
Here the trim() actually leave a leading space left of pi and slices one valid character on the right. One big BUT: this only happens to Linux cross-compiler targeting Android platform, downloaded from Android NDK page. Where as MSVC on Windows, GCC/Clang on Mac all run without problems. What might be the reason of this unexpected behavior?
- 主要語言
- C++
- 星號
- 131
- 分支
- 118
- PR 合併指標
- 30 天內沒有已合併 PR
環境準備
這個專案沒有提供開發容器、Dockerfile 或貢獻指南,環境需要你自己搭建:先看它的 README,通用步驟見我們的新手貢獻指南。
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
boostorg/algorithm 的其他 Issue
-
難度 5/5 一週以上 新手友好度 30/100
-
難度 5/5 一週以上 新手友好度 35/100
-
難度 5/5 一週以上 新手友好度 35/100
-
難度 5/5 一週以上 新手友好度 25/100
-
難度 4/5 3-5 天 新手友好度 25/100
查看 boostorg/algorithm 的全部 Issue
相似的 Issue
-
難度 1/5 1 小時以內 新手友好度 76/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 76/100
維護者通常 1 天內回覆
-
難度 1/5 1 小時以內 新手友好度 65/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 77/100
ros-navigation/navigation2#6648 · 1 則留言 ·
維護者通常 1 天內回覆
-
[BUG] OTA Requestor accepts reserved provider endpoint 0xFFFF可能已有人在做 @Chapoly1305 今天認領。 未關閉
難度 2/5 1-3 小時 新手友好度 72/100
project-chip/connectedhomeip#74742 ·
維護者通常 1 天內回覆