---
spec: JVMS
title: "The Java Virtual Machine Specification"
edition: "Java SE 24 Edition"
java_version: 24
chapter: "Chapter 4. The class File Format"
section: "4.10.1.9.aastore"
heading: "aastore"
parent: "4.10.1.9. Type Checking Instructions"
source: https://docs.oracle.com/javase/specs/jvms/se24/html/jvms-4.html#jvms-4.10.1.9.aastore
id: "4.10.1.9.aastore"
url: https://jvm.obfuscated.software/jvms/se24/4.10.1.9.aastore.html
raw: https://jvm.obfuscated.software/jvms/se24/4.10.1.9.aastore.md
---

# aastore

An *aastore* instruction is type safe iff one can validly pop types matching `Object`, `int`, and an array of `Object` off the incoming operand stack yielding the outgoing type state.

```
instructionIsTypeSafe(aastore, _Environment, _Offset, StackFrame,
                      NextStackFrame, ExceptionStackFrame) :-
    isBootstrapLoader(BL),
    canPop(StackFrame,
           [class('java/lang/Object', BL),
            int,
            arrayOf(class('java/lang/Object', BL))],
           NextStackFrame),
    exceptionStackFrame(StackFrame, ExceptionStackFrame).
```
