The following link may be helpful?
(How to avoid compile and upload errors in XIAO_BLE with ArduinoIDE2.0)