Remove unnecessary snake case variables.

Test: m nothing + TreeHugger
Change-Id: I99f7162944daa6c57c6ae4763261e108bb5cb6b1
This commit is contained in:
Jaewoong Jung
2020-12-21 09:11:10 -08:00
parent 1f8c272984
commit 18aefc1977
33 changed files with 204 additions and 204 deletions

View File

@@ -305,17 +305,17 @@ func apiCheckEnabled(ctx android.ModuleContext, apiToCheck ApiToCheck, apiVersio
}
func ignoreMissingModules(ctx android.BottomUpMutatorContext, apiToCheck *ApiToCheck) {
api_file := String(apiToCheck.Api_file)
removed_api_file := String(apiToCheck.Removed_api_file)
apiFile := String(apiToCheck.Api_file)
removedApiFile := String(apiToCheck.Removed_api_file)
api_module := android.SrcIsModule(api_file)
removed_api_module := android.SrcIsModule(removed_api_file)
apiModule := android.SrcIsModule(apiFile)
removedApiModule := android.SrcIsModule(removedApiFile)
if api_module == "" || removed_api_module == "" {
if apiModule == "" || removedApiModule == "" {
return
}
if ctx.OtherModuleExists(api_module) || ctx.OtherModuleExists(removed_api_module) {
if ctx.OtherModuleExists(apiModule) || ctx.OtherModuleExists(removedApiModule) {
return
}

View File

@@ -1505,11 +1505,11 @@ func (j *Module) compile(ctx android.ModuleContext, aaptSrcJar android.Path) {
j.compiledJavaSrcs = uniqueSrcFiles
j.compiledSrcJars = srcJars
enable_sharding := false
enableSharding := false
var headerJarFileWithoutJarjar android.Path
if ctx.Device() && !ctx.Config().IsEnvFalse("TURBINE_ENABLED") && !deps.disableTurbine {
if j.properties.Javac_shard_size != nil && *(j.properties.Javac_shard_size) > 0 {
enable_sharding = true
enableSharding = true
// Formerly, there was a check here that prevented annotation processors
// from being used when sharding was enabled, as some annotation processors
// do not function correctly in sharded environments. It was removed to
@@ -1535,7 +1535,7 @@ func (j *Module) compile(ctx android.ModuleContext, aaptSrcJar android.Path) {
extraJarDeps = append(extraJarDeps, errorprone)
}
if enable_sharding {
if enableSharding {
flags.classpath = append(flags.classpath, headerJarFileWithoutJarjar)
shardSize := int(*(j.properties.Javac_shard_size))
var shardSrcs []android.Paths

View File

@@ -371,8 +371,8 @@ func decodeSdkDep(ctx android.EarlyModuleContext, sdkContext sdkContext) sdkDep
jar := filepath.Join(dir, "android.jar")
// There's no aidl for other SDKs yet.
// TODO(77525052): Add aidl files for other SDKs too.
public_dir := filepath.Join("prebuilts", "sdk", sdkVersion.version.String(), "public")
aidl := filepath.Join(public_dir, "framework.aidl")
publicDir := filepath.Join("prebuilts", "sdk", sdkVersion.version.String(), "public")
aidl := filepath.Join(publicDir, "framework.aidl")
jarPath := android.ExistentPathForSource(ctx, jar)
aidlPath := android.ExistentPathForSource(ctx, aidl)
lambdaStubsPath := android.PathForSource(ctx, config.SdkLambdaStubsPath)

View File

@@ -1534,7 +1534,7 @@ func (module *SdkLibrary) CreateInternalModules(mctx android.DefaultableHookCont
hasSystemAndTestApis := sdkDep.hasStandardLibs()
module.sdkLibraryProperties.Generate_system_and_test_apis = hasSystemAndTestApis
missing_current_api := false
missingCurrentApi := false
generatedScopes := module.getGeneratedApiScopes(mctx)
@@ -1545,12 +1545,12 @@ func (module *SdkLibrary) CreateInternalModules(mctx android.DefaultableHookCont
p := android.ExistentPathForSource(mctx, path)
if !p.Valid() {
mctx.ModuleErrorf("Current api file %#v doesn't exist", path)
missing_current_api = true
missingCurrentApi = true
}
}
}
if missing_current_api {
if missingCurrentApi {
script := "build/soong/scripts/gen-java-current-api-files.sh"
p := android.ExistentPathForSource(mctx, script)