/*!
Copyright (c) 2026 Lenovo SSG BASD. All rights reserved.
@license Proprietary

This software is the confidential and proprietary property of Lenovo SSG BASD.
You shall not disclose such Confidential Information and shall use it only in
accordance with the terms of the license agreement.

--- Build Info ---
Version: 1.1.1
Build Time: 2026/2/26 17:21:00
Build Commit: 81e556ed827e2f043668506dae6fae8dbb9ef395
*/
import{parser as e}from"../../../@lezer/java/dist/index.js";import{LanguageSupport as t,LRLanguage as n,indentNodeProp as o,flatIndent as a,continuedIndent as l,delimitedIndent as r,foldNodeProp as c,foldInside as s}from"../../language/dist/index.js";const i=/* @__PURE__ */n.define({name:"java",parser:/* @__PURE__ */e.configure({props:[
/* @__PURE__ */o.add({IfStatement:/* @__PURE__ */l({except:/^\s*({|else\b)/}),TryStatement:/* @__PURE__ */l({except:/^\s*({|catch|finally)\b/}),LabeledStatement:a,SwitchBlock:e=>{let t=e.textAfter,n=/^\s*\}/.test(t),o=/^\s*(case|default)\b/.test(t);return e.baseIndent+(n?0:o?1:2)*e.unit},Block:/* @__PURE__ */r({closing:"}"}),BlockComment:()=>null,Statement:/* @__PURE__ */l({except:/^{/})}),
/* @__PURE__ */c.add({"Block SwitchBlock ClassBody ElementValueArrayInitializer ModuleBody EnumBody ConstructorBody InterfaceBody ArrayInitializer":s,BlockComment:e=>({from:e.from+2,to:e.to-2})})]}),languageData:{commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:case |default:|\{|\})$/}});function d(){return new t(i)}export{d as java,i as javaLanguage};